update-docker-bash.sh
· 402 B · Bash
Raw
#!/bin/bash
declare -a arr=("snikket" "plausible")
for i in "${arr[@]}"
do
if [ "$i" = "snikket" ]
then
echo
echo "snikket"
echo
cd /etc/snikket
docker compose pull
docker compose up -d
cd
elif [ "$i" = "plausible" ]
then
echo
echo "plausible"
echo
cd /home/airikr/docker/plausible
docker compose pull
docker compose up -d
cd
fi
done
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 |