1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-24 23:38:09 +00:00

build: add BITCOIN_ONLY variable to docker build scripts

This commit is contained in:
Pavol Rusnak 2019-09-04 12:16:55 +02:00
parent 9d5bac50fd
commit bfe01707b1
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D
2 changed files with 4 additions and 2 deletions

View File

@ -14,6 +14,7 @@ IMAGE=trezor-core-build.$TOOLCHAIN_FLAVOR
TAG=${1:-master}
REPOSITORY=${2:-trezor}
PRODUCTION=${PRODUCTION:-0}
BITCOIN_ONLY=${BITCOIN_ONLY:-0}
if [ "$REPOSITORY" = "local" ]; then
REPOSITORY=file:///local/
@ -27,7 +28,7 @@ USER=$(ls -lnd . | awk '{ print $3 }')
GROUP=$(ls -lnd . | awk '{ print $4 }')
mkdir -p $(pwd)/build/core
docker run -t -v $(pwd):/local -v $(pwd)/build/core:/build:z --user="$USER:$GROUP" $IMAGE /bin/sh -c "\
docker run -t -v $(pwd):/local -v $(pwd)/build/core:/build:z --env BITCOIN_ONLY="$BITCOIN_ONLY" --user="$USER:$GROUP" $IMAGE /bin/sh -c "\
cd /tmp && \
git clone $REPOSITORY trezor-firmware && \
cd trezor-firmware/core && \

View File

@ -6,10 +6,11 @@ cd "$(dirname $0)/.."
BOOTLOADER_COMMIT=${1:-HEAD}
FIRMWARE_COMMIT=${2:-HEAD}
IMAGE=trezor-mcu-build
BITCOIN_ONLY=${BITCOIN_ONLY:-0}
USER=$(ls -lnd . | awk '{ print $3 }')
GROUP=$(ls -lnd . | awk '{ print $4 }')
docker build -t "$IMAGE" ci/
docker run -it -v $(pwd):/src:z --user="$USER:$GROUP" "$IMAGE" \
docker run -it -v $(pwd):/src:z --env BITCOIN_ONLY="$BITCOIN_ONLY" --user="$USER:$GROUP" "$IMAGE" \
/src/legacy/script/fullbuild "$BOOTLOADER_COMMIT" "$FIRMWARE_COMMIT"