Theodore Grey | 15a535d | 2022-03-01 09:46:23 +0100 | [diff] [blame] | 1 | - job: |
Theodore Grey | d88e6d0 | 2022-02-01 14:13:52 +0100 | [diff] [blame] | 2 | name: tf-a-docs-watcher |
Paul Sokolovsky | bacbb15 | 2023-07-16 20:30:12 +0300 | [diff] [blame] | 3 | node: docker-amd64-tf-a-jammy |
Theodore Grey | d88e6d0 | 2022-02-01 14:13:52 +0100 | [diff] [blame] | 4 | project-type: freestyle |
| 5 | concurrent: false |
Chris Kay | 675db4f | 2025-06-24 14:14:34 +0100 | [diff] [blame] | 6 | 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. |
Theodore Grey | a345137 | 2022-02-22 10:19:47 +0100 | [diff] [blame] | 7 | disabled: false |
Theodore Grey | d88e6d0 | 2022-02-01 14:13:52 +0100 | [diff] [blame] | 8 | builders: |
Chris Kay | 675db4f | 2025-06-24 14:14:34 +0100 | [diff] [blame] | 9 | - 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 . |
Theodore Grey | d88e6d0 | 2022-02-01 14:13:52 +0100 | [diff] [blame] | 17 | properties: |
Chris Kay | 675db4f | 2025-06-24 14:14:34 +0100 | [diff] [blame] | 18 | - build-discarder: |
| 19 | days-to-keep: 60 |
| 20 | num-to-keep: 10 |
Theodore Grey | d88e6d0 | 2022-02-01 14:13:52 +0100 | [diff] [blame] | 21 | triggers: |
Chris Kay | 675db4f | 2025-06-24 14:14:34 +0100 | [diff] [blame] | 22 | - gerrit: |
| 23 | silent: true |
| 24 | server-name: review.trustedfirmware.org |
| 25 | projects: |
| 26 | - branches: |
| 27 | - branch-compare-type: PLAIN |
| 28 | branch-pattern: master |
| 29 | project-compare-type: PLAIN |
| 30 | project-pattern: TF-A/trusted-firmware-a |
| 31 | trigger-on: |
| 32 | - ref-updated-event |
Theodore Grey | d88e6d0 | 2022-02-01 14:13:52 +0100 | [diff] [blame] | 33 | wrappers: |
Chris Kay | 675db4f | 2025-06-24 14:14:34 +0100 | [diff] [blame] | 34 | - timestamps |
| 35 | - credentials-binding: |
| 36 | - text: |
| 37 | credential-id: TF-A-RTD-API-TOKEN |
| 38 | variable: RTD_TOKEN |
Theodore Grey | d88e6d0 | 2022-02-01 14:13:52 +0100 | [diff] [blame] | 39 | parameters: |
Chris Kay | 675db4f | 2025-06-24 14:14:34 +0100 | [diff] [blame] | 40 | - string: |
| 41 | name: RTD_BRANCHES |
| 42 | default: master |
| 43 | description: | |
| 44 | The branch, or branches, to rebuild the documentation for. |
Theodore Grey | d88e6d0 | 2022-02-01 14:13:52 +0100 | [diff] [blame] | 45 | publishers: |
Chris Kay | 675db4f | 2025-06-24 14:14:34 +0100 | [diff] [blame] | 46 | - workspace-cleanup |