Skip to content

validate CRDs GH actions step #725

validate CRDs GH actions step

validate CRDs GH actions step #725

Workflow file for this run

name: controller tests
on:
pull_request:
paths:
- 'cyclops-ctrl/**'
push:
paths:
- 'cyclops-ctrl/**'
branches:
- main
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Unit tests
working-directory: cyclops-ctrl
run: |
make unit-test
validate-crd-updates:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Validate Module
working-directory: cyclops-ctrl
run: |
diff \
<(yq 'select(.kind == "CustomResourceDefinition" and .metadata.name == "modules.cyclops-ui.com")' ../install/cyclops-install.yaml) \
<(yq -N config/crd/bases/cyclops-ui.com_modules.yaml)
- name: Validate TemplateAuthRule
working-directory: cyclops-ctrl
run: |
diff \
<(yq 'select(.kind == "CustomResourceDefinition" and .metadata.name == "templateauthrules.cyclops-ui.com")' ../install/cyclops-install.yaml) \
<(yq -N config/crd/bases/cyclops-ui.com_templateauthrules.yaml)
- name: Validate TemplateStore
working-directory: cyclops-ctrl
run: |
diff \
<(yq 'select(.kind == "CustomResourceDefinition" and .metadata.name == "templatestores.cyclops-ui.com")' ../install/cyclops-install.yaml) \
<(yq -N config/crd/bases/cyclops-ui.com_templatestores.yaml)