From 09ead9ff4aa3dfd2e490498633979f2cbc42fb4b Mon Sep 17 00:00:00 2001 From: Elian Loraux <elian.loraux@tetras-libre.fr> Date: Mon, 28 Apr 2025 10:02:03 +0200 Subject: [PATCH] source env --- upgrade/traefik_fail2ban.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/upgrade/traefik_fail2ban.sh b/upgrade/traefik_fail2ban.sh index 64e5cdf..ad8ebd0 100644 --- a/upgrade/traefik_fail2ban.sh +++ b/upgrade/traefik_fail2ban.sh @@ -1,5 +1,15 @@ #!/bin/bash +DIR=$(realpath $(dirname $0)/..) +if [ ! -e $DIR/main.env ] +then + echo "Please copy in racine of NoCloud Auto Installer main.env.sample to main.env and edit it" + exit 1 +else + echo "Environment file loaded" +fi +. $DIR/main.env + cat <<EOF > /etc/fail2ban/jail.d/nocloud_traefik.conf [traefik-auth] enabled = true -- GitLab