|
4 | 4 | workflow_dispatch: |
5 | 5 | repository_dispatch: |
6 | 6 | types: [trigger-npm-update] |
| 7 | + |
7 | 8 | jobs: |
8 | 9 | update-dependency: |
9 | 10 | runs-on: ubuntu-latest |
10 | 11 | permissions: |
11 | 12 | id-token: write |
12 | | - contents: read |
| 13 | + contents: write |
| 14 | + pull-requests: write |
13 | 15 | strategy: |
14 | 16 | matrix: |
15 | | - branch: [main, 'v/24.1', 'v/23.3', api] |
| 17 | + branch: [main, 'v24.3', 'v/24.2', 'v/24.1', api] |
| 18 | + |
16 | 19 | steps: |
17 | 20 | - uses: aws-actions/configure-aws-credentials@v4 |
18 | 21 | with: |
19 | 22 | aws-region: ${{ vars.RP_AWS_CRED_REGION }} |
20 | 23 | role-to-assume: arn:aws:iam::${{ secrets.RP_AWS_CRED_ACCOUNT_ID }}:role/${{ vars.RP_AWS_CRED_BASE_ROLE_NAME }}${{ github.event.repository.name }} |
| 24 | + |
21 | 25 | - uses: aws-actions/aws-secretsmanager-get-secrets@v2 |
22 | 26 | with: |
23 | 27 | secret-ids: | |
24 | 28 | ,sdlc/prod/github/actions_bot_token |
25 | 29 | parse-json-secrets: true |
| 30 | + |
26 | 31 | - name: Checkout the repository |
27 | 32 | uses: actions/checkout@v4 |
28 | 33 | with: |
29 | 34 | ref: ${{ matrix.branch }} |
30 | 35 | token: ${{ env.ACTIONS_BOT_TOKEN }} |
| 36 | + |
31 | 37 | - name: Set up Node.js |
32 | 38 | uses: actions/setup-node@v4 |
33 | 39 | with: |
34 | 40 | node-version: '18' |
| 41 | + |
35 | 42 | - name: Install dependencies |
36 | 43 | run: npm install |
| 44 | + |
37 | 45 | - name: Update @redpanda-data/docs-extensions-and-macros |
38 | 46 | run: npm update @redpanda-data/docs-extensions-and-macros |
39 | | - - name: Commit changes |
40 | | - run: | |
41 | | - git config --global user.name "vbotbuildovich" |
42 | | - git config --global user.email "[email protected]" |
43 | | - git add package.json package-lock.json |
44 | | - git commit -m "auto-docs: Update @redpanda-data/docs-extensions-and-macros" |
45 | | - git push origin ${{ matrix.branch }} |
46 | | - env: |
47 | | - ACCESS_TOKEN: ${{ env.ACTIONS_BOT_TOKEN }} |
| 47 | + |
| 48 | + - name: Create Pull Request |
| 49 | + uses: peter-evans/create-pull-request@v6 |
| 50 | + with: |
| 51 | + token: ${{ env.ACTIONS_BOT_TOKEN }} |
| 52 | + commit-message: auto-docs: Update @redpanda-data/docs-extensions-and-macros |
| 53 | + labels: auto-docs |
| 54 | + title: auto-docs: Update @redpanda-data/docs-extensions-and-macros |
| 55 | + body: | |
| 56 | + This PR updates `@redpanda-data/docs-extensions-and-macros` using `npm update`. |
| 57 | + branch: update/docs-extensions-and-macros-${{ matrix.branch }} |
| 58 | + base: ${{ matrix.branch }} |
0 commit comments