chore: auto-commit 2026-03-30 06:58
This commit is contained in:
parent
c5beca562b
commit
6b8186f496
1 changed files with 9 additions and 9 deletions
18
setup.sh
18
setup.sh
|
|
@ -1,8 +1,8 @@
|
|||
#!/bin/bash
|
||||
# ==============================================================================
|
||||
# Wallarm Deployment Setup Script
|
||||
# Wallarm Deployment Setup Script (Forgejo Version)
|
||||
# ==============================================================================
|
||||
# Downloads all necessary Wallarm deployment scripts from GitLab repository
|
||||
# Downloads all necessary Wallarm deployment scripts from the Forgejo repository
|
||||
# and makes them executable.
|
||||
# ==============================================================================
|
||||
|
||||
|
|
@ -17,8 +17,9 @@ CYAN='\033[0;36m'
|
|||
BOLD='\033[1m'
|
||||
NC='\033[0m'
|
||||
|
||||
# Base URLs for GitLab raw content
|
||||
GITLAB_BASE="https://git.sechpoint.app/customer-engineering/wallarm/raw/branch/main/setup.sh"
|
||||
# Forgejo raw URL base
|
||||
FORGEJO_BASE="https://git.sechpoint.app/customer-engineering/wallarm/raw/branch/main"
|
||||
|
||||
SCRIPTS=(
|
||||
"wallarm-ct-check.sh"
|
||||
"wallarm-ct-deploy.sh"
|
||||
|
|
@ -26,7 +27,7 @@ SCRIPTS=(
|
|||
"wallarm-ct-uninstall.sh"
|
||||
)
|
||||
|
||||
# Detect download command (curl preferred, fallback to wget)
|
||||
# Detect download command
|
||||
if command -v curl >/dev/null 2>&1; then
|
||||
DOWNLOAD_CMD="curl -fL -O"
|
||||
DOWNLOAD_NAME="curl"
|
||||
|
|
@ -39,10 +40,9 @@ else
|
|||
exit 1
|
||||
fi
|
||||
|
||||
# Function to download a script
|
||||
download_script() {
|
||||
local script="$1"
|
||||
local url="${GITLAB_BASE}/${script}"
|
||||
local url="${FORGEJO_BASE}/${script}"
|
||||
echo -e "${YELLOW}Downloading ${script}...${NC}"
|
||||
if [ -f "$script" ]; then
|
||||
echo -e "${YELLOW} File already exists. Overwrite? (y/N)${NC}"
|
||||
|
|
@ -73,12 +73,12 @@ download_script() {
|
|||
clear
|
||||
echo -e "${BLUE}${BOLD}"
|
||||
echo "╔══════════════════════════════════════════════════════════════╗"
|
||||
echo "║ WALLARM DEPLOYMENT SETUP SCRIPT ║"
|
||||
echo "║ WALLARM DEPLOYMENT SETUP SCRIPT (Forgejo) ║"
|
||||
echo "║ Downloads all necessary deployment tools ║"
|
||||
echo "╚══════════════════════════════════════════════════════════════╝${NC}"
|
||||
echo
|
||||
|
||||
# Check for existing scripts and provide option to skip all
|
||||
# Check for existing scripts
|
||||
if ls wallarm-ct-*.sh 2>/dev/null | grep -q .; then
|
||||
echo -e "${YELLOW}Existing Wallarm scripts found.${NC}"
|
||||
echo -e "${YELLOW}Do you want to re-download all? (y/N)${NC}"
|
||||
|
|
|
|||
Loading…
Reference in a new issue