blob: 5e035c689fae1f0d641c1ff87ef18264768b5d5f [file] [log] [blame]
Chris Kay9666e882022-08-25 15:53:44 +01001- job:
2 name: tf-a-docs-watcher
Paul Sokolovsky43972d62023-07-16 20:23:51 +03003 node: docker-amd64-tf-a-jammy
Chris Kay9666e882022-08-25 15:53:44 +01004 project-type: freestyle
5 concurrent: false
Chris Kaybb674402025-06-24 15:20:02 +01006 description: Triggers whenever a code change is merged into the master branch of the TF-A repository. Executes a webhook to trigger the ReadTheDocs service to build a fresh copy of the documentation for one or more branches.
Chris Kay1c929b92022-10-11 10:46:31 +01007 disabled: false
Chris Kay9666e882022-08-25 15:53:44 +01008 builders:
Chris Kaybb674402025-06-24 15:20:02 +01009 - shell: |-
10 #!/bin/bash -e
11 echo "Trigger ReadTheDocs build on the $RTD_BRANCHES branch and the latest version"
12 RTD_API="https://readthedocs.org/api/v3/projects/trustedfirmware-a"
13 echo "Trigger build $RTD_BRANCHES branch"
14 curl -s -X POST -H "Authorization: Token ${RTD_TOKEN}" ${RTD_API}/versions/$RTD_BRANCHES/builds/ | jq .
15 echo "Trigger build latest version"
16 curl -s -X POST -H "Authorization: Token ${RTD_TOKEN}" ${RTD_API}/versions/latest/builds/ | jq .
Chris Kay9666e882022-08-25 15:53:44 +010017 properties:
Chris Kaybb674402025-06-24 15:20:02 +010018 - build-discarder:
19 days-to-keep: 60
20 num-to-keep: 10
Chris Kay9666e882022-08-25 15:53:44 +010021 wrappers:
Chris Kaybb674402025-06-24 15:20:02 +010022 - timestamps
23 - credentials-binding:
24 - text:
25 credential-id: TF-A-RTD-API-TOKEN
26 variable: RTD_TOKEN
Chris Kay9666e882022-08-25 15:53:44 +010027 parameters:
Chris Kaybb674402025-06-24 15:20:02 +010028 - string:
29 name: RTD_BRANCHES
30 default: master
31 description: |
32 The branch, or branches, to rebuild the documentation for.
Chris Kay9666e882022-08-25 15:53:44 +010033 publishers:
Chris Kaybb674402025-06-24 15:20:02 +010034 - workspace-cleanup