Skip to content

Commit 3bbf77c

Browse files
committed
Add check for existing 'frontend' Docker network in install task
1 parent 7169890 commit 3bbf77c

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Taskfile.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,14 @@ tasks:
2020
desc: Install OS2BorgerPC Adminsite
2121
cmds:
2222
- task _show_preinstall_notes
23+
- |
24+
# Check if the external network 'frontend' exists, create if not
25+
if ! docker network ls --format '{{.Name}}' | grep -wq frontend; then
26+
echo "Creating external network 'frontend'"
27+
docker network create frontend
28+
else
29+
echo "External network 'frontend' already exists"
30+
fi
2331
- task _version_file
2432
- task _prepare_nginx_conf
2533
- echo "Installing"

0 commit comments

Comments
 (0)