Added helm charts (25.10.1) #6
This file contains hidden or 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: Helm | |
| on: | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - "deploy/charts/**" | |
| pull_request: | |
| paths: | |
| - "deploy/charts/**" | |
| env: | |
| HELM_VERSION: "v3.10.2" | |
| permissions: | |
| contents: write | |
| jobs: | |
| lint-crds: | |
| name: CRDs | |
| runs-on: ubuntu-latest | |
| env: | |
| CT_CONFIG: hack/config/chart-testing/mariadb-enterprise-operator-crds.yaml | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup Helm | |
| uses: azure/setup-helm@v4 | |
| with: | |
| version: ${{ env.HELM_VERSION }} | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.9" | |
| - name: Set up chart-testing | |
| uses: helm/chart-testing-action@v2.6.1 | |
| - name: List changed | |
| id: list-changed | |
| run: | | |
| changed=$(ct list-changed --config $CT_CONFIG) | |
| if [[ -n "$changed" ]]; then | |
| echo "changed=true" >> $GITHUB_OUTPUT | |
| fi | |
| - name: Lint | |
| if: steps.list-changed.outputs.changed == 'true' | |
| run: ct lint --config $CT_CONFIG | |
| - name: Cluster | |
| if: steps.list-changed.outputs.changed == 'true' | |
| run: make cluster | |
| - name: Test install | |
| if: steps.list-changed.outputs.changed == 'true' | |
| run: ct install --config $CT_CONFIG | |
| lint-operator: | |
| name: Operator | |
| runs-on: ubuntu-latest | |
| env: | |
| CT_CONFIG: hack/config/chart-testing/mariadb-enterprise-operator.yaml | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup Helm | |
| uses: azure/setup-helm@v4 | |
| with: | |
| version: ${{ env.HELM_VERSION }} | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.9" | |
| - name: Set up chart-testing | |
| uses: helm/chart-testing-action@v2.6.1 | |
| - name: List changed | |
| id: list-changed | |
| run: | | |
| changed=$(ct list-changed --config $CT_CONFIG) | |
| if [[ -n "$changed" ]]; then | |
| echo "changed=true" >> $GITHUB_OUTPUT | |
| fi | |
| - name: Lint | |
| if: steps.list-changed.outputs.changed == 'true' | |
| run: ct lint --config $CT_CONFIG | |
| - name: Cluster | |
| if: steps.list-changed.outputs.changed == 'true' | |
| run: make cluster | |
| - name: Test install | |
| if: steps.list-changed.outputs.changed == 'true' | |
| run: ct install --config $CT_CONFIG --helm-extra-set-args "--set=crds.enabled=true" | |
| release: | |
| name: Release | |
| runs-on: ubuntu-latest | |
| needs: | |
| - lint-crds | |
| - lint-operator | |
| if: github.ref == 'refs/heads/main' | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| token: "${{ secrets.GITHUB_TOKEN }}" | |
| - name: Configure Git | |
| run: | | |
| git config user.name "$GITHUB_ACTOR" | |
| git config user.email "$GITHUB_ACTOR@users.noreply.github.com" | |
| - name: Install Helm | |
| uses: azure/setup-helm@v4 | |
| - name: Run chart-releaser | |
| id: chart-releaser | |
| uses: helm/chart-releaser-action@v1.7.0 | |
| env: | |
| CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | |
| with: | |
| charts_dir: deploy/charts | |
| skip_existing: "true" | |
| pages_branch: gh-pages | |
| packages_with_index: true | |
| mark_as_latest: false |