This commit is contained in:
Bastien COIGNOUX
2026-04-26 22:50:35 +02:00
parent 1813603bb3
commit 89c37cf28d
8 changed files with 362 additions and 0 deletions

31
deploy/hooks.json.example Normal file
View File

@ -0,0 +1,31 @@
[
{
"id": "jira-descours-deploy",
"execute-command": "/config/deploy.sh",
"command-working-directory": "/",
"trigger-rule": {
"and": [
{
"match": {
"type": "value",
"value": "refs/heads/main",
"parameter": {
"source": "payload",
"name": "ref"
}
}
},
{
"match": {
"type": "value",
"value": "CHANGEME_SECRET_TOKEN",
"parameter": {
"source": "url",
"name": "token"
}
}
}
]
}
}
]

View File

@ -0,0 +1,8 @@
#!/bin/sh
# Copier vers le NAS (ex. /volume1/docker/jira-descours/deploy.sh), chmod +x,
# adapter APP_DIR et redémarrer le conteneur « webhook » qui linvoque.
set -e
APP_DIR="/volume1/docker/jira-descours/src"
cd "$APP_DIR"
git pull --ff-only
docker compose --env-file .env.deploy -f docker-compose.yml up -d --build