node-distro/s6/minimal/etc/cont-init.d/40-aqua-ipfs
Anatolios Laskaris 2488f2b317
fix: Manage IPFS addresses settings (#71)
* Manage IPFS addresses settings

* Typo

* Fix README

* Fix readme

* Use tcp entrypoint

* Apply suggestions from code review

Co-authored-by: folex <0xdxdy@gmail.com>

* Fix README

Co-authored-by: folex <0xdxdy@gmail.com>
2022-11-21 12:44:12 +02:00

19 lines
389 B
Plaintext

#!/usr/bin/with-contenv bash
aqua_ipfs_vars=(
"FLUENCE_ENV_AQUA_IPFS_EXTERNAL_API_MULTIADDR"
"FLUENCE_ENV_AQUA_IPFS_LOCAL_API_MULTIADDR"
)
error=0
for var in ${aqua_ipfs_vars[@]}; do
if [[ -z ${!var} ]]; then
echo "$var must be defined in order for aqua-ipfs to work"
error=1
fi
done
if ((error)); then
echo "removing aqua-ipfs builtin"
rm -rf /builtins/aqua-ipfs
fi