From 8e172e1fd10d16a41bcf30749bbedcf54f3d6370 Mon Sep 17 00:00:00 2001 From: CanbiZ <47820557+MickLesk@users.noreply.github.com> Date: Mon, 19 May 2025 14:38:26 +0200 Subject: [PATCH] Create argus-install.sh --- install/argus-install.sh | 99 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 install/argus-install.sh diff --git a/install/argus-install.sh b/install/argus-install.sh new file mode 100644 index 0000000..1b7d35e --- /dev/null +++ b/install/argus-install.sh @@ -0,0 +1,99 @@ +#!/usr/bin/env bash + +# Copyright (c) 2021-2025 community-scripts ORG +# Author: MickLesk (CanbiZ) +# License: MIT | https://github.com/community-scripts/ProxmoxVED/raw/main/LICENSE + +source /dev/stdin <<<"$FUNCTIONS_FILE_PATH" +color +verb_ip6 +catch_errors +setting_up_container +network_check +update_os + +msg_info "Installing Dependencies" +$STD apt-get install -y \ + jq +msg_ok "Installed Dependencies" + +msg_info "Setup Argus" +RELEASE=$(curl -fsSL https://api.github.com/repos/release-argus/Argus/releases/latest | jq -r .tag_name | sed 's/^v//') +mkdir -p /opt/argus +curl -fsSL "https://github.com/release-argus/Argus/releases/download/${RELEASE}/Argus-${RELEASE}.linux-amd64" -o /opt/argus/Argus +chmod +x /opt/argus/Argus +msg_ok "Setup Argus" + +msg_info "Setup Argus Config" +cat </opt/argus/config.yml +settings: + log: + level: INFO + timestamps: false + data: + database_file: data/argus.db + web: + listen_host: 0.0.0.0 + listen_port: 8080 + route_prefix: / + +defaults: + service: + options: + interval: 30m + semantic_versioning: true + latest_version: + allow_invalid_certs: false + use_prerelease: false + dashboard: + auto_approve: true + webhook: + desired_status_code: 201 + +service: + release-argus/argus: + latest_version: + type: github + url: release-argus/argus + dashboard: + icon: https://raw.githubusercontent.com/release-argus/Argus/master/web/ui/react-app/public/favicon.svg + icon_link_to: https://release-argus.io + web_url: https://github.com/release-argus/Argus/blob/master/CHANGELOG.md + + community-scripts/ProxmoxVE: + latest_version: + type: github + url: community-scripts/ProxmoxVE + use_prerelease: false + dashboard: + icon: https://raw.githubusercontent.com/community-scripts/ProxmoxVE/refs/heads/main/misc/images/logo.png + icon_link_to: https://helper-scripts.com/ + web_url: https://github.com/community-scripts/ProxmoxVE/releases +EOF +echo "${RELEASE}" >/opt/argus_version.txt +msg_ok "Setup Config" + +msg_info "Creating Service" +cat </etc/systemd/system/argus.service +[Unit] +Description=Argus +After=network.target +[Service] +Type=simple +WorkingDirectory=/opt/argus +ExecStart=/opt/argus/Argus +Restart=on-failure +RestartSec=5 +[Install] +WantedBy=multi-user.target +EOF +systemctl enable -q --now argus +msg_ok "Created Service" + +motd_ssh +customize + +msg_info "Cleaning up" +$STD apt-get -y autoremove +$STD apt-get -y autoclean +msg_ok "Cleaned"