mirror of
https://github.com/CringeStudios/element-desktop.git
synced 2025-01-18 23:44:59 +01:00
c2896a9caf
Each build command via Docker for Linux builds creates a separate writable layer from scratch, so anything shared between commands needs to persist on the host. This adds the container's GPG keys, so that the riot-web GPG key can be imported in one step and verified in the next. Fixes https://github.com/vector-im/riot-web/issues/13545
21 lines
761 B
Bash
Executable File
21 lines
761 B
Bash
Executable File
#!/bin/bash
|
|
|
|
docker inspect riot-desktop-dockerbuild 2> /dev/null > /dev/null
|
|
if [ $? != 0 ]; then
|
|
echo "Docker image riot-desktop-dockerbuild not found. Have you run yarn run docker:setup?"
|
|
exit 1
|
|
fi
|
|
|
|
# Taken from https://www.electron.build/multi-platform-build#docker
|
|
docker run --rm -ti \
|
|
--env-file <(env | grep -iE '^BUILDKITE_API_KEY=') \
|
|
--env ELECTRON_CACHE="/root/.cache/electron" \
|
|
--env ELECTRON_BUILDER_CACHE="/root/.cache/electron-builder" \
|
|
-v ${PWD}:/project \
|
|
-v ${PWD}/docker/node_modules:/project/node_modules \
|
|
-v ${PWD}/docker/.hak:/project/.hak \
|
|
-v ${PWD}/docker/.gnupg:/root/.gnupg \
|
|
-v ~/.cache/electron:/root/.cache/electron \
|
|
-v ~/.cache/electron-builder:/root/.cache/electron-builder \
|
|
riot-desktop-dockerbuild "$@"
|