Skip policy-ifgen-build when building for docs.rs (#14) #1
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Publish Release Artifacts On Tag Creation" | |
on: | |
push: | |
tags: | |
- "*" | |
workflow_dispatch: | |
workflow_call: | |
inputs: | |
workflow: | |
required: true | |
type: string | |
secrets: | |
CC_BUILD_TOKEN: | |
required: true | |
GH_DOTCOM_TOKEN: | |
required: true | |
jobs: | |
release: | |
strategy: | |
matrix: | |
runner: ["self-hosted-linux-amd64"] | |
runs-on: ${{ matrix.runner }} | |
steps: | |
- name: Create Release | |
id: release | |
uses: spideroak-inc/[email protected] | |
with: | |
allowUpdates: true | |
prerelease: false | |
makeLatest: legacy | |
token: ${{ secrets.CC_BUILD_TOKEN }} | |
outputs: | |
upload-url: ${{ steps.release.outputs.upload_url }} | |
build: | |
uses: ./.github/workflows/doc.yml | |
with: | |
workflow: doc | |
secrets: | |
CC_BUILD_TOKEN: ${{ secrets.CC_BUILD_TOKEN }} | |
GH_DOTCOM_TOKEN: ${{ secrets.GH_DOTCOM_TOKEN }} | |
publish-docs: | |
needs: | |
- release | |
- build | |
strategy: | |
matrix: | |
runner: ["self-hosted-linux-amd64"] | |
runs-on: ${{ matrix.runner }} | |
steps: | |
- name: Download doc artifacts | |
uses: actions/download-artifact@v3 | |
with: | |
name: docs | |
path: docs | |
- name: List files | |
run: ls -R -al | |
- name: Upload docs to tagged release | |
uses: actions/[email protected] | |
env: | |
GITHUB_TOKEN: ${{ secrets.CC_BUILD_TOKEN }} | |
with: | |
upload_url: ${{ needs.release.outputs.upload-url }} | |
asset_path: docs/docs.zip | |
asset_name: docs/docs.zip | |
asset_content_type: application/zip |