mirror of
https://github.com/logos-storage/codex-factory.git
synced 2026-01-02 13:03:07 +00:00
* feat: add cleanup script in favor of many build trials * feat: create docker images from specific state of spawned bee clients * chore: add generated Docker files to git * refactor: remove individual Docker files and create one common * feat: remove Dockerfile creation and simplify the script * feat: update common dockerfile on build * refactor: remove generated Dockerfile from git * chore: add generated Dockerfile to gitignore * chore: ignore Dockerfile * feat: check whether system environment variable is defined * feat: common variable handling, new bee.sh functionalities and params * feat: blockchain docker image build script * feat: environment script to start the created images * docs: amend readme * feat: add bee image prefix env variable and its handlings * feat: env variable handling + image prefix handling * docs: amend readme * feat: docker image prune * docs: amend readme * chore: echo for sudo password * chore: echo for sudo password * fix: environment queen logging * chore: remove commented out code * refactor: use osx compatible local variable init * refactor: use shell check extension and make the script osx compatible * fix: stop blockchain container as well on interrupting * fix: rule out commented lines from env checking * refactor: remove unnecessary echo * refactor: remove cat command from the .env grep * refactor: add some quotes to variable references where is necessary
23 lines
728 B
Bash
Executable File
23 lines
728 B
Bash
Executable File
#!/bin/bash
|
|
MY_PATH=$(dirname "$0")
|
|
MY_PATH=$( cd "$MY_PATH" && pwd )
|
|
# Check used system variable set
|
|
BEE_ENV_PREFIX=$("$MY_PATH/utils/env-variable-value.sh" BEE_ENV_PREFIX)
|
|
|
|
NETWORK="$BEE_ENV_PREFIX-network"
|
|
NAME="$BEE_ENV_PREFIX-blockchain"
|
|
CONTAINER_IN_DOCKER=$(docker container ls -qaf name=$NAME)
|
|
|
|
if [ -z "$CONTAINER_IN_DOCKER" ]; then
|
|
# necessary "-b 1" because anyway the Bee throws Error: waiting backend sync: Post "http://swarm-test-blockchain:9545": EOF
|
|
docker run \
|
|
-p 127.0.0.1:9545:9545 \
|
|
--network $NETWORK \
|
|
--name $NAME -d \
|
|
trufflesuite/ganache-cli ganache-cli \
|
|
-d -i 4020 -h 0.0.0.0 -p 9545 \
|
|
-b 1 \
|
|
--db swarm-testchain --gasLimit 6721975
|
|
else
|
|
docker start $NAME
|
|
fi |