N8N first run script
Run Tests on Branches / Frontend Mobile Tests (push) Has been skipped
Run Tests on Branches / Parapharmacy API Tests (push) Has been skipped
Run Tests on Branches / Detect Changes (push) Successful in 13s
Run Tests on Branches / Backend Tests (push) Has been skipped
Run Tests on Branches / Frontend Tests (push) Has been skipped
Run Tests on Branches / PIP Platform Tests (push) Has been skipped
Run Tests on Branches / Frontend Mobile Tests (push) Has been skipped
Run Tests on Branches / Parapharmacy API Tests (push) Has been skipped
Run Tests on Branches / Detect Changes (push) Successful in 13s
Run Tests on Branches / Backend Tests (push) Has been skipped
Run Tests on Branches / Frontend Tests (push) Has been skipped
Run Tests on Branches / PIP Platform Tests (push) Has been skipped
This commit is contained in:
Executable
+22
@@ -0,0 +1,22 @@
|
||||
#!/bin/sh
|
||||
# One-shot init: import workflows into n8n on first deploy.
|
||||
# Skips if already imported (flag file in shared volume).
|
||||
set -e
|
||||
|
||||
FLAG="/home/node/.n8n/.workflows-imported"
|
||||
|
||||
if [ -f "$FLAG" ]; then
|
||||
echo "[n8n-init] Workflows already imported, skipping."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "[n8n-init] Waiting for n8n to be ready..."
|
||||
until wget -qO /dev/null http://n8n:5678/healthz 2>/dev/null; do
|
||||
sleep 2
|
||||
done
|
||||
|
||||
echo "[n8n-init] Importing workflows from /home/node/workflows/..."
|
||||
n8n import:workflow --separate --input=/home/node/workflows/
|
||||
|
||||
touch "$FLAG"
|
||||
echo "[n8n-init] Import complete."
|
||||
Reference in New Issue
Block a user