fix(helm): update chart democratic-csi ( 0.15.0 → 0.15.1 ) #10081
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: Flux Local | |
| on: | |
| pull_request: | |
| branches: ["main"] | |
| jobs: | |
| filter: | |
| name: Flux Local - Filter | |
| runs-on: ubuntu-latest | |
| outputs: | |
| changed-files: ${{ steps.changed-files.outputs.changed_files }} | |
| steps: | |
| - name: Get Changed Files | |
| id: changed-files | |
| uses: bjw-s-labs/action-changed-files@a9a36fb08ce06db9b02fbd8026cc2c0945eb9841 # v0.6.0 | |
| with: | |
| patterns: |- | |
| .github/workflows/flux-local.yaml | |
| kubernetes/**/* | |
| apps/**/* | |
| clusters: | |
| if: ${{ needs.filter.outputs.changed-files != '[]' }} | |
| needs: filter | |
| name: Flux Local - Cluster List | |
| runs-on: ubuntu-latest | |
| outputs: | |
| cluster-list: ${{ steps.list.outputs.clusters }} | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - id: list | |
| name: Get Cluster List | |
| working-directory: ./kubernetes/clusters | |
| run: | | |
| echo "clusters=$(ls -d * | jq --raw-input --slurp --compact-output 'split("\n")[:-1]')" >> ${GITHUB_OUTPUT} | |
| test: | |
| if: ${{ needs.filter.outputs.changed-files != '[]' }} | |
| needs: [filter, clusters] | |
| name: Flux Local - Test | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| cluster: ${{ fromJSON(needs.clusters.outputs.cluster-list) }} | |
| fail-fast: false | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Setup Flux CLI | |
| uses: fluxcd/flux2/action@04acaec6161ac4fb1a82ffafa88901c03271d34f # v2.8.6 | |
| - uses: allenporter/flux-local/action/test@4d666add25002f550dc0dbe8b2b2f25859169b34 # 8.2.0 | |
| with: | |
| path: kubernetes/clusters/${{ matrix.cluster }}/flux | |
| enable-helm: true | |
| diff: | |
| if: ${{ needs.filter.outputs.changed-files != '[]' }} | |
| needs: [filter, clusters] | |
| name: Flux Local - Diff | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| pull-requests: write | |
| strategy: | |
| matrix: | |
| cluster: ${{ fromJSON(needs.clusters.outputs.cluster-list) }} | |
| fail-fast: false | |
| steps: | |
| - name: Checkout Pull Request Branch | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| path: pull | |
| - name: Checkout Default Branch | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| ref: "${{ github.event.repository.default_branch }}" | |
| path: default | |
| - name: Generate Manifests for Pull Request Branch | |
| uses: docker://ghcr.io/allenporter/flux-local:v8.0.0 | |
| with: | |
| args: >- | |
| build all | |
| --enable-helm | |
| --skip-kinds VMAlert,VMRule | |
| --output pr.yaml | |
| /github/workspace/pull/kubernetes/clusters/${{ matrix.cluster }}/flux | |
| - name: Generate Manifests for Default Branch | |
| uses: docker://ghcr.io/allenporter/flux-local:v8.0.0 | |
| with: | |
| args: >- | |
| build all | |
| --enable-helm | |
| --skip-kinds VMAlert,VMRule | |
| --output main.yaml | |
| /github/workspace/default/kubernetes/clusters/${{ matrix.cluster }}/flux | |
| - name: Install dyff | |
| uses: jaxxstorm/action-install-gh-release@25e24d2d23ae098373794ef1d6faecb48ee52da8 # v3.0.0 | |
| with: | |
| repo: homeport/dyff | |
| # renovate: datasource=github-releases depName=homeport/dyff | |
| tag: v1.12.0 | |
| - name: Generate Diff | |
| id: diff | |
| run: | | |
| DYFFCMD=( | |
| dyff between main.yaml pr.yaml | |
| --ignore-order-changes | |
| --exclude-regexp "/metadata/labels/app.kubernetes.io/version" | |
| --exclude-regexp "/metadata/labels/chart" | |
| --exclude-regexp "/metadata/labels/helm.sh/chart" | |
| --exclude-regexp "/metadata/annotations/config.kubernetes.io/index" | |
| --exclude-regexp "/metadata/annotations/internal.config.kubernetes.io/index" | |
| # during local generation we generate a new ca cert everytime so ignore these fields | |
| --exclude-regexp "webhooks.*.victoriametrics.com.clientConfig.caBundle" | |
| --exclude "spec.template.metadata.annotations.checksum/secret" | |
| ) | |
| summary=$("${DYFFCMD[@]}" --output brief) | |
| echo summary="${summary//$'\n'/ }" >> $GITHUB_OUTPUT | |
| # Generate full diff | |
| "${DYFFCMD[@]}" --output github > diff-results | |
| # Check diff size (GitHub comment limit is ~65k characters, we'll use 50k as safe limit) | |
| diff_size=$(wc -c < diff-results) | |
| echo "Diff size: $diff_size characters" | |
| if [ "$diff_size" -gt 50000 ]; then | |
| echo "diff_too_large=true" >> $GITHUB_OUTPUT | |
| echo "diff_size=$diff_size" >> $GITHUB_OUTPUT | |
| # Create truncated version for comment (first 40k chars + truncation notice) | |
| head -c 40000 diff-results > diff-truncated | |
| echo "" >> diff-truncated | |
| echo "" >> diff-truncated | |
| echo "... (diff truncated - full diff available in artifacts)" >> diff-truncated | |
| echo "Total diff size: $diff_size characters" >> diff-truncated | |
| # Set truncated diff for comment | |
| EOF=$(dd if=/dev/urandom bs=15 count=1 status=none | base64) | |
| echo 'diff<<$EOF' >> $GITHUB_OUTPUT | |
| cat diff-truncated >> $GITHUB_OUTPUT | |
| echo '$EOF' >> $GITHUB_OUTPUT | |
| else | |
| echo "diff_too_large=false" >> $GITHUB_OUTPUT | |
| # Set full diff for comment | |
| EOF=$(dd if=/dev/urandom bs=15 count=1 status=none | base64) | |
| echo 'diff<<$EOF' >> $GITHUB_OUTPUT | |
| cat diff-results >> $GITHUB_OUTPUT | |
| echo '$EOF' >> $GITHUB_OUTPUT | |
| fi | |
| # Always add to step summary (GitHub handles large summaries better) | |
| echo '### Diff' >> $GITHUB_STEP_SUMMARY | |
| echo '```diff' >> $GITHUB_STEP_SUMMARY | |
| if [ "$diff_size" -gt 100000 ]; then | |
| # Even step summary has limits, so truncate for very large diffs | |
| head -c 90000 diff-results >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "... (diff truncated in summary - full diff available in artifacts)" >> $GITHUB_STEP_SUMMARY | |
| else | |
| cat diff-results >> $GITHUB_STEP_SUMMARY | |
| fi | |
| echo '```' >> $GITHUB_STEP_SUMMARY | |
| # Save full diff for artifact upload | |
| cp diff-results "diff-${{ matrix.cluster }}.txt" | |
| - name: Generate Token | |
| uses: actions/create-github-app-token@1b10c78c7865c340bc4f6099eb2f838309f1e8c3 # v3.1.1 | |
| id: app-token | |
| with: | |
| app-id: ${{ vars.BOT_APP_ID }} | |
| private-key: ${{ secrets.BOT_APP_PRIVATE_KEY }} | |
| - if: ${{ steps.diff.outputs.diff != '' }} | |
| name: Upload Full Diff as Artifact | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | |
| with: | |
| name: flux-diff-${{ matrix.cluster }} | |
| path: diff-${{ matrix.cluster }}.txt | |
| retention-days: 30 | |
| - if: ${{ steps.diff.outputs.diff != '' && steps.diff.outputs.diff_too_large != 'true' }} | |
| name: Add Comment (Normal Size) | |
| uses: marocchino/sticky-pull-request-comment@0ea0beb66eb9baf113663a64ec522f60e49231c0 # v3.0.4 | |
| with: | |
| GITHUB_TOKEN: ${{ steps.app-token.outputs.token }} | |
| header: ${{ github.event.pull_request.number }}/kubernetes-dyff/${{ matrix.cluster }} | |
| message: | | |
| ### ${{ matrix.cluster }} Diff | |
| There were ${{ steps.diff.outputs.summary }} | |
| ```diff | |
| ${{ steps.diff.outputs.diff }} | |
| ``` | |
| - if: ${{ steps.diff.outputs.diff != '' && steps.diff.outputs.diff_too_large == 'true' }} | |
| name: Add Comment (Large Diff) | |
| uses: marocchino/sticky-pull-request-comment@0ea0beb66eb9baf113663a64ec522f60e49231c0 # v3.0.4 | |
| with: | |
| GITHUB_TOKEN: ${{ steps.app-token.outputs.token }} | |
| header: ${{ github.event.pull_request.number }}/kubernetes-dyff/${{ matrix.cluster }} | |
| message: | | |
| ### ${{ matrix.cluster }} Diff | |
| There were ${{ steps.diff.outputs.summary }} | |
| ⚠️ **Large Diff Detected** (${{ steps.diff.outputs.diff_size }} characters) | |
| The diff is too large to display in a comment. You can: | |
| 1. 📥 **Download the full diff** from the [workflow artifacts](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) | |
| 2. 📋 **View in the workflow summary** (may be truncated if very large) | |
| 3. 👀 **Preview below** (truncated to first 40k characters) | |
| <details> | |
| <summary>🔍 Click to view truncated diff preview</summary> | |
| ```diff | |
| ${{ steps.diff.outputs.diff }} | |
| ``` | |
| </details> | |
| 💡 **Tip**: Large diffs often indicate significant changes. Consider reviewing the full diff artifact for complete details. | |
| - if: ${{ steps.diff.outputs.diff == '' }} | |
| name: Add Comment | |
| uses: marocchino/sticky-pull-request-comment@0ea0beb66eb9baf113663a64ec522f60e49231c0 # v3.0.4 | |
| with: | |
| GITHUB_TOKEN: ${{ steps.app-token.outputs.token }} | |
| header: ${{ github.event.pull_request.number }}/kubernetes-dyff/${{ matrix.cluster }} | |
| hide: true | |
| hide_classify: "OUTDATED" | |
| success: | |
| if: ${{ !cancelled() }} | |
| needs: ["diff"] | |
| name: Flux Local - Success | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Any jobs failed? | |
| if: ${{ contains(needs.*.result, 'failure') }} | |
| run: exit 1 | |
| - name: All jobs passed or skipped? | |
| if: ${{ !(contains(needs.*.result, 'failure')) }} | |
| run: echo "All jobs passed or skipped" && echo "${{ toJSON(needs.*.result) }}" |