Update Guardian installation and update scripts to use example docker-compose.yml and remove unnecessary comments
This commit is contained in:
parent
544150a57a
commit
e48f2c35a8
@ -39,10 +39,8 @@ function update_script() {
|
||||
msg_ok "Stopped $APP"
|
||||
|
||||
msg_info "Updating $APP to v${RELEASE}"
|
||||
# Download new docker-compose.yml
|
||||
curl -fsSL -o docker-compose.yml "https://raw.githubusercontent.com/HydroshieldMKII/Guardian/main/docker-compose.yml"
|
||||
curl -fsSL -o docker-compose.yml "https://raw.githubusercontent.com/HydroshieldMKII/Guardian/main/docker-compose.example.yml"
|
||||
|
||||
# Pull new Docker images
|
||||
docker compose pull
|
||||
|
||||
echo "${RELEASE}" >/opt/${APP}_version.txt
|
||||
@ -54,7 +52,6 @@ function update_script() {
|
||||
msg_ok "Started $APP"
|
||||
|
||||
msg_info "Cleaning Up"
|
||||
rm -f /tmp/plex-guard.db.backup
|
||||
docker system prune -f
|
||||
msg_ok "Cleanup Completed"
|
||||
|
||||
|
@ -21,7 +21,6 @@ $STD apt-get install -y \
|
||||
lsb-release
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
# Install Docker
|
||||
msg_info "Installing Docker"
|
||||
curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
|
||||
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian $(lsb_release -cs) stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
@ -30,28 +29,21 @@ $STD apt-get install -y docker-ce docker-ce-cli containerd.io docker-compose-plu
|
||||
systemctl enable --now docker
|
||||
msg_ok "Installed Docker"
|
||||
|
||||
# Setup Guardian
|
||||
msg_info "Setting up Guardian"
|
||||
mkdir -p /opt/Guardian
|
||||
cd /opt/Guardian
|
||||
|
||||
# Download docker-compose.yml from repository
|
||||
RELEASE=$(curl -fsSL https://api.github.com/repos/HydroshieldMKII/Guardian/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
|
||||
curl -fsSL -o docker-compose.yml "https://raw.githubusercontent.com/HydroshieldMKII/Guardian/main/docker-compose.example.yml"
|
||||
|
||||
# Create data directory for persistent storage
|
||||
mkdir -p data
|
||||
|
||||
echo "${RELEASE}" >/opt/Guardian_version.txt
|
||||
msg_ok "Setup Guardian"
|
||||
|
||||
# Start Guardian with Docker Compose
|
||||
msg_info "Starting Guardian"
|
||||
cd /opt/Guardian
|
||||
docker compose up -d
|
||||
msg_ok "Started Guardian"
|
||||
|
||||
# Create systemd service to manage Docker Compose
|
||||
msg_info "Creating Guardian Service"
|
||||
cat <<EOF >/etc/systemd/system/guardian.service
|
||||
[Unit]
|
||||
|
Loading…
x
Reference in New Issue
Block a user