-
Notifications
You must be signed in to change notification settings - Fork 4
42 lines (38 loc) · 1.64 KB
/
nightly-cod-platform-deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: nightly-cod-platform-deploy
on:
schedule:
- cron: "15 6 * * 1-5"
jobs:
nightly-cod-platform-deploy:
runs-on: "ubuntu-latest"
env:
GH_TOKEN: ${{ github.token }}
steps:
- name: Checkout sources
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Check the status of the last nightly
id: check-latest-nightly-status
uses: ./.github/actions/check-latest-nightly-status
- name: Deploy the potential Centreon-on-Demand nightly instance of the day
if: ${{ steps.check-latest-nightly-status.outputs.last_nightly_result == 'success' }}
run: |
set -x
echo "[INFO]: Deploying a nightly CoD instance with the latest developments."
curl -X POST \
-H "Authorization: Bearer ${{ secrets.CENTREON_TECHNIQUE_PAT }}" \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/centreon/centreon-on-demand/dispatches \
-d '{"event_type": "deploy-nightly-platform",
"client_payload": {
"bu": "RD",
"deployment_profile": "Standard profile",
"remote_server_number": 1,
"poller_number": 1,
"instance_features": "Alma9 - MariaDB",
"centreon_branch": "develop",
"custom_centreon_web_admin_password": "${{ secrets.COD_NIGHTLY_INSTANCE_ADMIN_PWD }}",
"configured_resources": "true",
"install_business_modules": "false"
}
}'
shell: bash