airikr 修订了这个 Gist . 跳至此修订
1 file changed, 27 insertions
update-docker-bash.sh(file created)
@@ -0,0 +1,27 @@ | |||
1 | + | #!/bin/bash | |
2 | + | declare -a arr=("snikket" "plausible") | |
3 | + | ||
4 | + | for i in "${arr[@]}" | |
5 | + | do | |
6 | + | if [ "$i" = "snikket" ] | |
7 | + | then | |
8 | + | echo | |
9 | + | echo "snikket" | |
10 | + | echo | |
11 | + | cd /etc/snikket | |
12 | + | docker compose pull | |
13 | + | docker compose up -d | |
14 | + | cd | |
15 | + | ||
16 | + | elif [ "$i" = "plausible" ] | |
17 | + | then | |
18 | + | echo | |
19 | + | echo "plausible" | |
20 | + | echo | |
21 | + | cd /home/airikr/docker/plausible | |
22 | + | docker compose pull | |
23 | + | docker compose up -d | |
24 | + | cd | |
25 | + | ||
26 | + | fi | |
27 | + | done |
更新
更早