Skip to content

Commit

Permalink
Improve docker file init
Browse files Browse the repository at this point in the history
  • Loading branch information
NHAS committed Jun 11, 2023
1 parent 376d376 commit 7241f48
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions docker_entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@

if [ ! -f /cfg/config.json ]; then
echo "No config file found, generating from example. Ensure /data is mounted for persistence"
cp /tmp/example_config.json /cfg/config.json
sed -i "s|AN EXAMPLE KEY|$(wg genkey)|" /cfg/config.json
wag gen-config- out /cfg/config.json
sed -i "s|\"devices.db\"|\"/data/devices.db\"|" /cfg/config.json
echo "Please edit your newly generated config file and start again"
exit
echo "Config generated, you may want to edit the advanced options and start again"
fi

# trap for all processes created inside this block; a single Ctrl+C will stop them all
Expand Down

0 comments on commit 7241f48

Please sign in to comment.