Skip to content

Commit

Permalink
fix inputs
Browse files Browse the repository at this point in the history
  • Loading branch information
arturo-seijas committed May 22, 2024
1 parent ffc34ce commit b274456
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions .github/workflows/publish_charm.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ on:
workflow_call:
inputs:
channel:
required: true
type: string
required: false
description: 'Destination Channel'
identifier:
type: string
Expand Down Expand Up @@ -51,9 +51,18 @@ env:
OWNER: ${{ github.repository_owner }}

jobs:
select-channel:
runs-on: ubuntu-latest
outputs:
destination-channel: ${{ steps.select-channel.outputs.name }}
steps:
- name: Select charmhub channel
uses: canonical/charming-actions/[email protected]
id: select-channel
publish-charm:
name: Publish charm to ${{ inputs.channel }}
name: Publish charm to ${{ inputs.channel || needs.select-channel.outputs.destination-channel }}
runs-on: ubuntu-latest
needs: [select-channel]
outputs:
charm-directory: ${{ steps.publish.outputs.charm-directory }}
steps:
Expand Down Expand Up @@ -84,7 +93,7 @@ jobs:
charmcraft-channel: ${{ inputs.charmcraft-channel }}
credentials: ${{ secrets.CHARMHUB_TOKEN }}
github-token: ${{ secrets.GITHUB_TOKEN }}
channel: ${{ inputs.channel }}
channel: ${{ inputs.channel || needs.select-channel.outputs.destination-channel }}
tag-prefix: ${{ inputs.tag-prefix }}
upload-image: false
draft-publish-docs:
Expand Down

0 comments on commit b274456

Please sign in to comment.