We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f79dc33 commit 5b48e34Copy full SHA for 5b48e34
import.sh
@@ -8,6 +8,19 @@ if [ -f "$ROTATED_LOG_FILE" ]; then
8
echo "Log rotation successful. Processing the rotated log file."
9
# Call the import script
10
python3 /app/import_logs.py --dry-run "$ROTATED_LOG_FILE" --url "$MATOMO_URL" --token-auth "$API_TOKEN"
11
+
12
+ # Find the PID of the traefik process
13
+ TRAEFIK_PID=$(pgrep traefik)
14
15
+ # Check if the PID was found
16
+ if [ -n "$TRAEFIK_PID" ]; then
17
+ # Send USR1 signal to the traefik process
18
+ kill -USR1 "$TRAEFIK_PID"
19
+ echo "Sent USR1 signal to traefik process with PID $TRAEFIK_PID"
20
+ else
21
+ echo "Traefik process not found."
22
+ exit 1
23
+ fi
24
else
25
echo "Rotated log file not found."
26
exit 1
0 commit comments