Fixing Docker entrypoint for storage node (#212)
This commit is contained in:
parent
3644d77b45
commit
1f7d77ae69
@ -2,15 +2,9 @@
|
||||
set -euo pipefail
|
||||
|
||||
# Create a new farmer, if the ID for an existing farmer isn't specified.
|
||||
if [ -z "${PSID}" ]; then
|
||||
if [[ -z $PSID ]]; then
|
||||
mkdir -p "${PS_DIR}"
|
||||
export PSID=$(./piecestore-farmer create \
|
||||
--pieceStoreHost=${PUBLIC_IP} \
|
||||
--pieceStorePort=${RPC_PORT} \
|
||||
--kademliaPort=${KAD_PORT} \
|
||||
--kademliaHost=${KAD_HOST} \
|
||||
--kademliaListenPort=${KAD_LISTEN_PORT} \
|
||||
--dir=${PS_DIR} | awk '/created/ { print $2 }')
|
||||
export PSID=$(./piecestore-farmer create | awk '/created/ { print $2 }')
|
||||
echo "Created farmer $PSID"
|
||||
fi
|
||||
exec ./piecestore-farmer start $PSID
|
||||
|
Loading…
Reference in New Issue
Block a user