KFLUXINRA-2965: Fix misbehaving kflux-fedora-01 cluster apps #7406
Workflow file for this run
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: Forbid ClusterPolicies outside Policies component | |
| on: | |
| pull_request: | |
| branches: [ main ] | |
| paths: | |
| - .github/workflows/forbid-clusterpolicies.yaml | |
| - hack/forbid-clusterpolicies.sh | |
| - 'components/**' | |
| - '!components/policies/**' | |
| jobs: | |
| forbid-clusterpolicies: | |
| name: Forbid ClusterPolicies outside Policies component | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Kustomize | |
| uses: multani/action-setup-kustomize@v1 | |
| with: | |
| version: 5.6.0 | |
| - name: Run forbid-clusterpolicies script | |
| env: | |
| OUTPUT: GITHUB | |
| run: | | |
| find argo-cd-apps components -name 'kustomization.yaml' \ | |
| ! -path '*/k-components/*' \ | |
| ! -path 'components/policies/*' \ | |
| ! -path 'components/repository-validator/staging/*' \ | |
| ! -path 'components/repository-validator/production/*' \ | |
| ! -path 'components/monitoring/blackbox/staging/*' \ | |
| ! -path 'components/monitoring/blackbox/production/*' \ | |
| | \ | |
| xargs -I {} -n1 -P8 bash -c './hack/forbid-clusterpolicies.sh $(dirname "{}")' |