My docker run commands for multinodes on Synology NAS

These are all the useful parameters that one storagenode can use, and the modifications that I use for the second node. Fill free to use them or not, is up to you. I put them here fore easy reference.
These work for Synology NAS and I run them in sudo su mode.
There is also the --user $(id -u):$(id -g) parameter, but I started without it. It seems that dosen’t work on Synology NAS.

NODE 1, MACHINE 1:
Run only once at install of first node:

echo "net.core.rmem_max=2500000" >> /etc/sysctl.conf
sysctl -w net.core.rmem_max=2500000
docker pull storjlabs/storagenode:latest
docker run --rm -e SETUP="true" \
	--mount type=bind,source="/volume1/Storj/Identity/storagenode/",destination=/app/identity \
	--mount type=bind,source="/volume1/Storj/",destination=/app/config \
	--name storagenode storjlabs/storagenode:latest

Run at installation or after stoping and removing node, after parameters change:

docker run -d --restart unless-stopped --stop-timeout 300 \
	-p 28967:28967/tcp \
	-p 28967:28967/udp \
	-p 14002:14002 \
	-p 5999:5999 \
	-e WALLET="...WALLET..." \
	-e EMAIL="...EMAIL..." \
	-e ADDRESS="...WAN_IP...:28967" \
	-e STORAGE="14TB" \
	--mount type=bind,source="/volume1/Storj/Identity/storagenode/",destination=/app/identity \
	--mount type=bind,source="/volume1/Storj/",destination=/app/config \
	--log-opt max-size=10m \
	--log-opt max-file=5 \
	--name storagenode storjlabs/storagenode:latest \
	--server.address=":28967" \
	--console.address=":14002" \
	--debug.addr=":5999" \
	--log.level=error \
	--filestore.write-buffer-size 4MiB \
	--pieces.write-prealloc-size 4MiB \
	--storage2.piece-scan-on-startup=true \
	--operator.wallet-features=zksync

NODE 2, MACHINE 1:
Run only once at install of seconde node:

docker run --rm -e SETUP="true" \
	--mount type=bind,source="/volume2/Storj2/Identity/storagenode/",destination=/app/identity \
	--mount type=bind,source="/volume2/Storj2/",destination=/app/config \
	--name storagenode2 storjlabs/storagenode:latest

Run at installation or after stoping and removing node, after parameters change:

docker run -d --restart unless-stopped --stop-timeout 300 \
	-p 28968:28968/tcp \
	-p 28968:28968/udp \
	-p 14003:14003 \
	-p 6000:6000 \
	-e WALLET="...WALLET..." \
	-e EMAIL="...EMAIL..." \
	-e ADDRESS="...WAP_IP...:28968" \
	-e STORAGE="14TB" \
	--mount type=bind,source="/volume2/Storj2/Identity/storagenode/",destination=/app/identity \
	--mount type=bind,source="/volume2/Storj2/",destination=/app/config \
	--log-opt max-size=10m \
	--log-opt max-file=5 \
	--name storagenode2 storjlabs/storagenode:latest \
	--server.address=":28968" \
	--console.address=":14003" \
	--debug.addr=":6000" \
	--log.level=error \
	--filestore.write-buffer-size 4MiB \
	--pieces.write-prealloc-size 4MiB \
	--storage2.piece-scan-on-startup=true \	
	--operator.wallet-features=zksync

Installing the WATCHTOWER - in this form, it will keep logs small and update all the containers, not only Storj’s:

docker pull storjlabs/watchtower
docker run -d --restart=always --log-opt max-size=10m --log-opt max-file=5 --name watchtower -v /var/run/docker.sock:/var/run/docker.sock storjlabs/watchtower --stop-timeout 300s --notifications-level error

Useful commands:

docker ps -a

docker stop -t 300 storagenode

docker rm storagenode

docker start storagenode


docker stop -t 300 storagenode2

docker rm storagenode2

docker start storagenode2


docker stop -t 300 watchtower

docker rm watchtower

docker start watchtower

Other useful commands:

	#check logs:
docker logs storagenode

docker logs watchtower

	#see the last 20 log entries:
docker logs --tail 20 storagenode

	#CLI dashboard:
docker exec -it storagenode /app/dashboard.sh

	#see all commands:
docker exec -it storagenode /app/storagenode help

	#execute commands:
docker exec -it storagenode /app/storagenode <<command>>