remove unneccessary lines
This commit is contained in:
@@ -4,5 +4,6 @@ Description=Send Gitea failure notification for %i
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/usr/local/bin/notify-gitea.sh %i failure
|
||||
# Load webhook URL from environment file
|
||||
# Load webhook URL: system-wide config first, user config overrides if present
|
||||
EnvironmentFile=-/etc/notify-gitea.conf
|
||||
EnvironmentFile=-%h/.config/notify-gitea.env
|
||||
|
||||
@@ -19,10 +19,13 @@ STATUS="${2:-unknown}"
|
||||
HOSTNAME=$(hostname)
|
||||
TIMESTAMP=$(date '+%Y-%m-%d %H:%M:%S %Z')
|
||||
|
||||
# Load config from file if not set
|
||||
# Load config from file if not set (system-wide, then user override)
|
||||
if [[ -f /etc/notify-gitea.conf ]]; then
|
||||
source /etc/notify-gitea.conf
|
||||
fi
|
||||
if [[ -f "${HOME}/.config/notify-gitea.env" ]]; then
|
||||
source "${HOME}/.config/notify-gitea.env"
|
||||
fi
|
||||
|
||||
# Validate required variables
|
||||
for var in GITEA_URL GITEA_TOKEN GITEA_OWNER GITEA_REPO; do
|
||||
|
||||
Reference in New Issue
Block a user