Skip to content

Build & release wheels #698

Build & release wheels

Build & release wheels #698

Workflow file for this run

name: Build & release wheels
on:
push:
branches:
- main
schedule:
- cron: '53 21 * * *' # Daily at 21:53 UTC
workflow_dispatch:
jobs:
collect-charms:
name: Collect charms
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install CLI
run: pipx install ./cli/
- name: Collect charms to build from charms.json
id: collect
run: collect-charms
outputs:
charms: ${{ steps.collect.outputs.charms }}
build:
strategy:
matrix:
charm: ${{ fromJSON(needs.collect-charms.outputs.charms) }}
name: ${{ matrix.charm.job_name }}
needs:
- collect-charms
uses: ./.github/workflows/build_charm.yaml
with:
github_repository: ${{ matrix.charm.github_repository }}
ref: ${{ matrix.charm.ref }}
relative_path_to_charmcraft_yaml: ${{ matrix.charm.relative_path_to_charmcraft_yaml }}
charm_index: ${{ matrix.charm.charm_index }}
release:
name: Release wheels
needs:
- build
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install CLI
run: pipx install ./cli/
- name: Create directory
run: mkdir -p ~/charmcraftcache-hub-ci/bases/
- name: Download wheels
uses: actions/download-artifact@v4
with:
path: ~/charmcraftcache-hub-ci/bases/
pattern: charm-*
- name: Create GitHub release
run: release
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: write # Needed to create release