Skip to content

Commit

Permalink
auto-generate PR to bump version in Docker Desktop
Browse files Browse the repository at this point in the history
Signed-off-by: Nicolas De Loof <[email protected]>
  • Loading branch information
ndeloof committed Mar 20, 2024
1 parent 86cd523 commit ce42886
Showing 1 changed file with 58 additions and 0 deletions.
58 changes: 58 additions & 0 deletions .github/workflows/pinata.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Bump Compose in Docker Desktop

on:
push:
tags:
- 'v*.*.*'
workflow_dispatch:

jobs:
pinata:
runs-on: ubuntu-latest
steps:
- name: Generate github token
uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ vars.COMPOSE_BOT_APP_ID }}
private-key: ${{ secrets.COMPOSE_BOT_APP_SECRET }}
repositories: "pinata"
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 1
repository: docker/pinata
ref: main
token: ${{ steps.app-token.outputs.token }}

- name: Bump version
run: |
tmpfile=$(mktemp)
cp build.json "$tmpfile"
jq '."docker-compose".version = "${{ github.ref_name }}".[1:64]' "$tmpfile" > build.json
rm -f "$tmpfile"
- name: Create Pull Request
uses: peter-evans/create-pull-request@v6
with:
token: ${{ steps.app-token.outputs.token }}
commit-message: "Bump Compose to ${{ github.ref_name }}"
branch: bump-docker-compose-${{ github.ref_name }}
title: "Bump Compose to ${{ github.ref_name }}"
labels: |
release
team/compose
body: |
### What this PR does
Bump [Docker Compose](https://github.com/docker/compose) to ${{ github.ref_name }}.
### Notes for the reviewer:
/focus-tests=kubernetes-compose-volume-registry
### Release notes
```release-note
- [Docker Compose ${{ github.ref_name }}](https://github.com/docker/compose/releases/tag/${{ github.ref_name }})
```

0 comments on commit ce42886

Please sign in to comment.