File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ source ./lib.sh
4+
5+ install_default_config snapclient snapcast
6+ start_app snapclient
7+
8+ echo " Do you want to install Airplay (shairport-sync) support? (yes/no)"
9+ read answer
10+
11+ if [ " $answer " = " yes" ]; then
12+ install_default_config shairport-sync shairport-sync
13+ start_app shairport-sync
14+ else
15+ echo " Skipping Airplay (shairport-sync)"
16+ fi
17+
18+ install_default_config watchtower
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ source ./lib.sh
4+
5+ start_app nginx-proxy-manager
6+ start_app dnsmasq
7+
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ echo " This script will install and start Docker. After running it you should install"
4+ echo " individual applications by running 'docker compose up -d' in each application's"
5+ echo " directory, or run an install script for a stack of applications."
6+ echo
7+ echo " This script uses ` sudo` to run items as root; you'll be prompted at least once at"
8+ echo " the start to enter your password in order to allow this"
9+
10+ sudo apt update && apt upgrade -y
11+ sudo apt install pwgen -y
12+
13+ if ! command -v docker & > /dev/null; then
14+ echo " Docker not found. Installing Docker..."
15+
16+ sudo apt install -y apt-transport-https ca-certificates curl software-properties-common
17+
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"
20+ sudo apt update
21+ sudo apt install -y docker-ce docker-ce-cli containerd.io
22+
23+ sudo systemctl start docker
24+ sudo systemctl enable docker
25+
26+ if command -v docker & > /dev/null; then
27+ echo " Docker installed successfully!"
28+ else
29+ echo " Docker installation failed."
30+ exit 1
31+ fi
32+ else
33+ echo " Docker is already installed."
34+ fi
Original file line number Diff line number Diff line change 1+ #! /bin/sh
2+
3+ source ./lib.sh
4+
5+ install_default_config zigbee2mqtt
6+ start_app zigbee2mqtt
7+
8+ install_default_config watchtower
9+ start_app zigbee2mqtt
Original file line number Diff line number Diff line change 1+ # lib.sh
2+ # meant to be included in other scripts and not run directly
3+ # source ./lib.sh
4+
5+ start_app () {
6+ pushd " $1 "
7+ if ! docker-compose ps | grep -q ' Up' ; then
8+ echo " Docker Compose project is not running. Starting it..."
9+ docker-compose up -d
10+ echo " $1 started."
11+ else
12+ echo " $1 is already running."
13+ fi
14+
15+ popd
16+ }
17+
18+ install_default_config(app, filename) {
19+ if [ -n " $2 " ]; then
20+ cp " $1 /config/$2 .default" " $1 /config/$2 "
21+ echo " Installed $1 /config/$2 - you should review this file for possible configuration changes"
22+ fi
23+
24+ if [ -f " $1 /.env.example" ]; then
25+ cp " $1 /.env.example" " $1 /.env"
26+ echo " installed $1 /.env - you should review this file for possible configuration changes"
27+ fi
28+ }
You can’t perform that action at this time.
0 commit comments