ThomasVitale / cloud-native-spring-in-action

🍃 Code samples and projects from the book "Cloud Native Spring in Action - With Spring Boot and Kubernetes" (Manning)
https://www.manning.com/books/cloud-native-spring-in-action
Apache License 2.0
444 stars 265 forks source link

Change kubeval by kubeconform #33

Closed ahmedkhabkhab closed 1 year ago

ahmedkhabkhab commented 1 year ago

kubeval is no longer maintained. Instead of doing a workaround by providing the schema URL, it would be better to use another tool like kubeconform.

      - name: Validate Kubernetes manifests
        uses: stefanprodan/kube-tools@v1
        with:
          kubectl: 1.26.1
          kubeconform: 0.5.0
          command: |
            kubeconform -strict -debug k8s

-debug is not needed. I just added it to show the schema URLs used to validate k8s yaml files

sewah2012 commented 1 year ago

Well spoted.

ThomasVitale commented 1 year ago

@ahmedkhabkhab thanks for your comment. Kubeconform is a great drop-in replacement for Kubeval. I have added a guide to the docs about how to replace Kubeval with Kubeconform. All examples in the book still work, but for real production scenarios I would recommend using Kubeconform. Perhaps I'll manage to do the switch in the upcoming reprint of the book, we'll see :)