|
| 1 | +#!/usr/bin/env bash |
| 2 | +_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func" |
| 3 | +source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func") |
| 4 | + |
| 5 | +# Copyright (c) 2021-2026 community-scripts ORG |
| 6 | +# Author: Nicolas Pastorello (opastorello) |
| 7 | +# License: MIT | https://github.com/community-scripts/ProxmoxVED/raw/main/LICENSE |
| 8 | +# Source: https://anubis.techaro.lol/ |
| 9 | + |
| 10 | +APP="Anubis" |
| 11 | +var_tags="${var_tags:-proxy;security}" |
| 12 | +var_cpu="${var_cpu:-1}" |
| 13 | +var_ram="${var_ram:-512}" |
| 14 | +var_disk="${var_disk:-4}" |
| 15 | +var_os="${var_os:-debian}" |
| 16 | +var_version="${var_version:-13}" |
| 17 | +var_unprivileged="${var_unprivileged:-1}" |
| 18 | +#var_arm64="${var_arm64:-no}" # unset = ask the user; set yes/no only when verified |
| 19 | + |
| 20 | +export var_anubis_target="${var_anubis_target:-}" |
| 21 | + |
| 22 | +header_info "$APP" |
| 23 | +variables |
| 24 | +color |
| 25 | +catch_errors |
| 26 | + |
| 27 | +function update_script() { |
| 28 | + header_info |
| 29 | + check_container_storage |
| 30 | + check_container_resources |
| 31 | + |
| 32 | + if [[ ! -f /etc/anubis/main.env ]]; then |
| 33 | + msg_error "No ${APP} Installation Found!" |
| 34 | + exit |
| 35 | + fi |
| 36 | + |
| 37 | + if check_for_gh_release "anubis" "TecharoHQ/anubis"; then |
| 38 | + msg_info "Stopping Service" |
| 39 | + systemctl stop anubis@main |
| 40 | + msg_ok "Stopped Service" |
| 41 | + |
| 42 | + fetch_and_deploy_gh_release "anubis" "TecharoHQ/anubis" "binary" |
| 43 | + |
| 44 | + msg_info "Starting Service" |
| 45 | + systemctl start anubis@main |
| 46 | + msg_ok "Started Service" |
| 47 | + msg_ok "Updated successfully!" |
| 48 | + fi |
| 49 | + exit |
| 50 | +} |
| 51 | + |
| 52 | +start |
| 53 | +build_container |
| 54 | +description |
| 55 | + |
| 56 | +msg_ok "Completed Successfully!\n" |
| 57 | +echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}" |
| 58 | +echo -e "${INFO}${YW}Access it using the following URL:${CL}" |
| 59 | +echo -e "${GATEWAY}${BGN}http://${IP}:8923${CL}" |
0 commit comments