docker
This commit is contained in:
31
deploy/hooks.json.example
Normal file
31
deploy/hooks.json.example
Normal 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"
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
8
deploy/nas-deploy.sh.example
Normal file
8
deploy/nas-deploy.sh.example
Normal 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 l’invoque.
|
||||
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
|
||||
Reference in New Issue
Block a user