eth-statediff-service/startup_script.sh
Roy Crihfield b91e854974 CI, build & docker updates
rm makefile
basic test
add chaindata fixture
simplify publish workflow
2023-09-02 04:29:33 +08:00

21 lines
650 B
Bash
Executable File

#!/bin/sh
# Exit if the variable tests fail
set -e
set +x
# Check the database variables are set
test "$VDB_COMMAND"
set +e
# docker must be run in privilaged mode for mounts to work
echo "Setting up /app/geth-rw overlayed /app/geth-ro"
mkdir -p /tmp/overlay && \
sudo mount -t tmpfs tmpfs /tmp/overlay && \
mkdir -p /tmp/overlay/upper && \
mkdir -p /tmp/overlay/work && \
mkdir -p /app/geth-rw && \
sudo mount -t overlay overlay -o lowerdir=/app/geth-ro,upperdir=/tmp/overlay/upper,workdir=/tmp/overlay/work /app/geth-rw && \
echo "Running the statediff service" && \
exec sudo ./eth-statediff-service "$VDB_COMMAND" --config=/config/config.toml