Skip to content

Commit 816fb01

Browse files
committed
source needs to be . for sh
updated repo management code fixed unneeded args in lib.sh
1 parent 10f60af commit 816fb01

5 files changed

Lines changed: 21 additions & 12 deletions

File tree

bin/install-audio-satellite.sh

100644100755
File mode changed.

bin/install-core.sh

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/sh
22

3-
source ./lib.sh
3+
. ./lib.sh
44

55
start_app nginx-proxy-manager
66
start_app dnsmasq

bin/install-debian.sh

100644100755
Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,26 @@ echo "This script uses `sudo` to run items as root; you'll be prompted at least
88
echo "the start to enter your password in order to allow this"
99

1010
sudo apt update && apt upgrade -y
11-
sudo apt install pwgen -y
11+
sudo apt install pwgen curl software-properties-common -y
1212

1313
if ! command -v docker &> /dev/null; then
1414
echo "Docker not found. Installing Docker..."
1515

16-
sudo apt install -y apt-transport-https ca-certificates curl software-properties-common
16+
# sudo apt install -y apt-transport-https ca-certificates curl software-properties-common
17+
sudo apt install -y apt-transport-https ca-certificates curl
18+
sudo install -m 0755 -d /etc/apt/keyrings
19+
sudo curl -fsSL https://download.docker.com/linux/debian/gpg -o /etc/apt/keyrings/docker.asc
20+
sudo chmod a+r /etc/apt/keyrings/docker.asc
21+
22+
# sudo add-apt-repository "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/debian $(lsb_release -cs) stable"
23+
sudo echo \
24+
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/debian \
25+
$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
26+
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
1727

18-
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo tee /etc/apt/trusted.gpg.d/docker.asc
19-
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/debian $(lsb_release -cs) stable"
2028
sudo apt update
21-
sudo apt install -y docker-ce docker-ce-cli containerd.io
29+
# sudo apt install -y docker-ce docker-ce-cli containerd.io
30+
sudo apt install -y docker-ce docker-ce-cli
2231

2332
sudo systemctl start docker
2433
sudo systemctl enable docker

bin/install-zigbee-satellite.sh

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/sh
22

3-
source ./lib.sh
3+
. ./bin/lib.sh
44

55
install_default_config zigbee2mqtt
66
start_app zigbee2mqtt

bin/lib.sh

100644100755
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,19 @@
33
# source ./lib.sh
44

55
start_app() {
6-
pushd "$1"
7-
if ! docker-compose ps | grep -q 'Up'; then
6+
cd "$1"
7+
if ! docker compose ps | grep -q 'Up'; then
88
echo "Docker Compose project is not running. Starting it..."
9-
docker-compose up -d
9+
docker compose up -d
1010
echo "$1 started."
1111
else
1212
echo "$1 is already running."
1313
fi
1414

15-
popd
15+
cd ..
1616
}
1717

18-
install_default_config(app, filename) {
18+
install_default_config() {
1919
if [ -n "$2" ]; then
2020
cp "$1/config/$2.default" "$1/config/$2"
2121
echo "Installed $1/config/$2 - you should review this file for possible configuration changes"

0 commit comments

Comments
 (0)