Skip to content

Commit

Permalink
feat(pub-techdocs): make bucket an input (#165)
Browse files Browse the repository at this point in the history
The name of the bucket doesn't need to be a secret, so make it an input
instead with a default.

Also, remove `inherit: secrets` from example, as no secrets are used in
the workflow now.
  • Loading branch information
zzehring authored Jun 27, 2024
1 parent a807bbb commit 3c8b714
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
1 change: 0 additions & 1 deletion .github/workflows/publish-techdocs.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ concurrency:
jobs:
publish-docs:
uses: grafana/shared-workflows/.github/workflows/publish-techdocs.yaml@main
secrets: inherit
with:
namespace: default
kind: component
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/publish-techdocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ on:
required: false
type: string
default: "false"
bucket:
description: "The name of the GCS bucket to which the docs will be published"
required: false
type: string
default: ops-us-east-0-backstage

jobs:
generate-and-publish-docs:
Expand Down Expand Up @@ -96,5 +101,5 @@ jobs:

- name: Publish docs site
if: inputs.publish
run: techdocs-cli publish --publisher-type googleGcs --storage-name ${{ secrets.BACKSTAGE_TECHDOCS_BUCKET_NAME }} --entity ${{ inputs.namespace }}/${{ inputs.kind }}/${{ inputs.name }}
run: techdocs-cli publish --publisher-type googleGcs --storage-name ${{ inputs.bucket }} --entity ${{ inputs.namespace }}/${{ inputs.kind }}/${{ inputs.name }}
working-directory: ${{ inputs.default-working-directory }}

0 comments on commit 3c8b714

Please sign in to comment.