Updated start.sh to check for .env

This commit is contained in:
2026-03-08 00:24:27 +01:00
parent 3b4c9ead6d
commit 52d7346588

View File

@@ -1,8 +1,12 @@
#!/bin/bash #!/bin/bash
# Copy this file to /usr/sbin/start to enable easy startup # Copy this file to /usr/sbin/start to enable easy startup
# cp start.sh /usr/sbin/start # sudo cp start.sh /usr/sbin/start
#docker stack deploy -c compose.yml ${PWD##*/} #docker stack deploy -c compose.yml ${PWD##*/}
env $(grep -v '^#' ${PWD}/.env | sed 's/#.*//' | xargs) docker stack deploy -c compose.yml ${PWD##*/} if [ -f ".env" ]; then
env $(grep -v '^#' ${PWD}/.env | sed 's/#.*//' | xargs) docker stack deploy -c compose.yml ${PWD##*/}
else
docker stack deploy -c compose.yml ${PWD##*/}
fi