diff --git a/app/build_containers.py b/app/build_containers.py index b3b6295e..20201a7c 100644 --- a/app/build_containers.py +++ b/app/build_containers.py @@ -86,6 +86,7 @@ def command(ctx, include, exclude, force_rebuild, extra_build_args): # TODO: make this configurable container_build_env = { "CERC_NPM_REGISTRY_URL": get_npm_registry_url(), + "CERC_GO_AUTH_TOKEN": config("CERC_GO_AUTH_TOKEN", default=""), "CERC_NPM_AUTH_TOKEN": config("CERC_NPM_AUTH_TOKEN", default=""), "CERC_REPO_BASE_DIR": dev_root_path, "CERC_CONTAINER_BASE_DIR": container_build_dir, diff --git a/app/data/container-build/cerc-plugeth-statediff/build.sh b/app/data/container-build/cerc-plugeth-statediff/build.sh index f1a9ffd5..15a77ef6 100755 --- a/app/data/container-build/cerc-plugeth-statediff/build.sh +++ b/app/data/container-build/cerc-plugeth-statediff/build.sh @@ -1,4 +1,10 @@ #!/usr/bin/env bash # Build cerc/plugeth-statediff source ${CERC_CONTAINER_BASE_DIR}/build-base.sh -docker build -t cerc/plugeth-statediff:local ${build_command_args} ${CERC_REPO_BASE_DIR}/plugeth-statediff +# This container build currently requires access to private dependencies in gitea +# so we check that the necessary access token has been supplied here, then pass it o the build +if [[ -z "${CERC_GO_AUTH_TOKEN}" ]]; then + echo "ERROR: CERC_GO_AUTH_TOKEN is not set" >&2 + exit 1 +fi +docker build -t cerc/plugeth-statediff:local ${build_command_args} --build-arg GIT_VDBTO_TOKEN=${CERC_GO_AUTH_TOKEN} ${CERC_REPO_BASE_DIR}/plugeth-statediff diff --git a/app/data/container-build/cerc-plugeth/build.sh b/app/data/container-build/cerc-plugeth/build.sh index 7c778877..1162a192 100755 --- a/app/data/container-build/cerc-plugeth/build.sh +++ b/app/data/container-build/cerc-plugeth/build.sh @@ -1,4 +1,10 @@ #!/usr/bin/env bash # Build cerc/plugeth source ${CERC_CONTAINER_BASE_DIR}/build-base.sh -docker build -t cerc/plugeth:local ${build_command_args} ${CERC_REPO_BASE_DIR}/plugeth +# This container build currently requires access to private dependencies in gitea +# so we check that the necessary access token has been supplied here, then pass it o the build +if [[ -z "${CERC_GO_AUTH_TOKEN}" ]]; then + echo "ERROR: CERC_GO_AUTH_TOKEN is not set" >&2 + exit 1 +fi +docker build -t cerc/plugeth:local ${build_command_args} --build-arg GIT_VDBTO_TOKEN=${CERC_GO_AUTH_TOKEN} ${CERC_REPO_BASE_DIR}/plugeth diff --git a/app/data/stacks/fixturenet-plugeth-tx/README.md b/app/data/stacks/fixturenet-plugeth-tx/README.md index 832ed749..50bfd919 100644 --- a/app/data/stacks/fixturenet-plugeth-tx/README.md +++ b/app/data/stacks/fixturenet-plugeth-tx/README.md @@ -12,6 +12,7 @@ See `stacks/fixturenet-eth/README.md` for more information. * cerc/tx-spammer ## Deploy the stack +Note: since some Go dependencies are currently private, `CERC_GO_AUTH_TOKEN` must be set to a valid Gitea access token before running the `build-containers` command. ``` $ laconic-so --stack fixturenet-plugeth-tx setup-repositories $ laconic-so --stack fixturenet-plugeth-tx build-containers