You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
59 lines
1.8 KiB
YAML
59 lines
1.8 KiB
YAML
name: docs-release
|
|
|
|
on:
|
|
release:
|
|
types:
|
|
- released
|
|
|
|
jobs:
|
|
open-pr:
|
|
runs-on: ubuntu-22.04
|
|
if: ${{ github.event.release.prerelease != true && github.repository == 'docker/buildx' }}
|
|
steps:
|
|
-
|
|
name: Checkout docs repo
|
|
uses: actions/checkout@v4
|
|
with:
|
|
token: ${{ secrets.GHPAT_DOCS_DISPATCH }}
|
|
repository: docker/docs
|
|
ref: main
|
|
-
|
|
name: Prepare
|
|
run: |
|
|
rm -rf ./_data/buildx/*
|
|
-
|
|
name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v2
|
|
-
|
|
name: Build docs
|
|
uses: docker/bake-action@v3
|
|
with:
|
|
source: ${{ github.server_url }}/${{ github.repository }}.git#${{ github.event.release.name }}
|
|
targets: update-docs
|
|
set: |
|
|
*.output=/tmp/buildx-docs
|
|
env:
|
|
DOCS_FORMATS: yaml
|
|
-
|
|
name: Copy files
|
|
run: |
|
|
cp /tmp/buildx-docs/out/reference/*.yaml ./_data/buildx/
|
|
-
|
|
name: Commit changes
|
|
run: |
|
|
git add -A .
|
|
-
|
|
name: Create PR on docs repo
|
|
uses: peter-evans/create-pull-request@153407881ec5c347639a548ade7d8ad1d6740e38
|
|
with:
|
|
token: ${{ secrets.GHPAT_DOCS_DISPATCH }}
|
|
push-to-fork: docker-tools-robot/docker.github.io
|
|
commit-message: "build: update buildx reference to ${{ github.event.release.name }}"
|
|
signoff: true
|
|
branch: dispatch/buildx-ref-${{ github.event.release.name }}
|
|
delete-branch: true
|
|
title: Update buildx reference to ${{ github.event.release.name }}
|
|
body: |
|
|
Update the buildx reference documentation to keep in sync with the latest release `${{ github.event.release.name }}`
|
|
draft: false
|