Skip to content

Use single (cached) build for tests & release (#182) #131

Use single (cached) build for tests & release (#182)

Use single (cached) build for tests & release (#182) #131

Workflow file for this run

# Copyright 2023 Canonical Ltd.
# See LICENSE file for licensing details.
name: Release to Charmhub
on:
push:
branches:
- main
jobs:
lib-check:
name: Check libraries
runs-on: ubuntu-22.04
timeout-minutes: 5
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Check libs
uses: canonical/charming-actions/[email protected]
with:
charmcraft-channel: latest/candidate # TODO: remove after charmcraft 3.3 stable release
credentials: "${{ secrets.CHARMHUB_TOKEN }}" # FIXME: current token will expire in 2023-07-04
github-token: "${{ secrets.GITHUB_TOKEN }}"
ci-tests:
needs:
- lib-check
uses: ./.github/workflows/ci.yaml
release:
name: Release to Charmhub
needs:
- lib-check
- ci-tests
uses: canonical/data-platform-workflows/.github/workflows/[email protected]
with:
charmcraft-snap-channel: latest/candidate # TODO: remove after charmcraft 3.3 stable release
channel: 3/edge
artifact-prefix: ${{ needs.ci-tests.outputs.artifact-prefix }}
secrets:
charmhub-token: ${{ secrets.CHARMHUB_TOKEN }}
permissions:
contents: write # Needed to create GitHub release