Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge Kubeconform with Kubeval #268

Open
yannh opened this issue Dec 15, 2020 · 7 comments
Open

Merge Kubeconform with Kubeval #268

yannh opened this issue Dec 15, 2020 · 7 comments

Comments

@yannh
Copy link

yannh commented Dec 15, 2020

Hello! I have been working on kubeconform for quite a while, a re-implementation of kubeval that solves a few of the issues with kubeval that bothered me most:

  • Some warnings cause kubeval to exit with 0, some with 1
  • The output is not ideal - -o json will output non JSON on top of the JSON output, same with -o tap.
  • the complexity of working with CRDs, though the (undocumented :() -additional-schema-locations is pretty close to what I added.
  • the use of comma separate values for -d is not very practical, can't use wildcards for example
    Kubeconform also downloads/validates over multiple go routines, so might be a tad faster.

Reasons for making a reimplementation, rather than sending patches to kubeval - was that some of the issues required significant re-architecting to implement - which makes for very large patches. Without acccess to the kubeval repository, it is very difficult to iterate efficiently.

Kubeconform has mostly reached feature-parity. The CLI, the API, and the outputs are all slightly different though.

This ticket is to track interest in merging both projects, the work that would be required to do so, and potentially discuss the level of compatibility we should aim for. I expect this might take a little bit of effort.

  • Is there interest / time to merge both projects?
  • Should I build an alternative CLI that is 100% compatible with kubeval? I do find the cli of kubeconform easier to work with and the use of goflags makes it easier to test. However 100% compatibility might make migration easier?
  • Should I build an API wrapper to support kubeval's API in kubeconform?

I would happily participate in the maintenance of the resulting project.

@yannh yannh changed the title Merge kubeconform with Kubeval Merge Kubeconform with Kubeval Dec 15, 2020
@carlossg
Copy link
Collaborator

I don't think Gareth has much time to work on kubeval.
If the code is a rewrite and CLI has different arguments, what's the point in merging? wouldn't then just say "try kubeconform" be better?

@yannh
Copy link
Author

yannh commented Jan 12, 2021

Hi @carlossg , it is a rewrite but reasonably similar and with feature parity. An objective could be to have kubeconform replicate kubeval's CLI interface, or library API. A benefit of merging would be to a/ make it easier for users to understand what tool to adopt b/ not duplicate the effort of maintenance / new features across two projects.

mrVanboy added a commit to kiwicom/dockerfiles that referenced this issue Feb 11, 2021
This commit adds alternative to the kubeval image. The new tool
provides better support and according to the docs is more up to date
with the latest k8s definitions.

Refs:
- https://github.com/yannh/kubeconformi
- instrumenta/kubeval#268
aexvir pushed a commit to kiwicom/dockerfiles that referenced this issue Feb 11, 2021
This commit adds alternative to the kubeval image. The new tool
provides better support and according to the docs is more up to date
with the latest k8s definitions.

Refs:
- https://github.com/yannh/kubeconformi
- instrumenta/kubeval#268
@groodt
Copy link

groodt commented Feb 18, 2021

Thanks @yannh CRD support would be great, so I support this initiative. Joining forces is often a good way to keep projects alive when contributors have other commitments. I'm only a user of kubeval, but it would be nice to know whether it is committed maintainers or if it is only in maintenance mode (which is fine).

@luisdavim
Copy link

Hi @carlossg , it is a rewrite but reasonably similar and with feature parity. An objective could be to have kubeconform replicate kubeval's CLI interface, or library API. A benefit of merging would be to a/ make it easier for users to understand what tool to adopt b/ not duplicate the effort of maintenance / new features across two projects.

So why did you start a separate project instead of contributing to this one?
I do agree joining forces would be great but I'm just a user...

@carlossg
Copy link
Collaborator

at this point I cannot recommend using kubeval because although I have commit access I don't have access to publish new releases

@till
Copy link

till commented Jan 9, 2023

@carlossg would you mind archiving the project if it is dormant? It would make it more obvious. :) And it can be undone later.

@carlossg
Copy link
Collaborator

carlossg commented Jan 9, 2023

I don't have access to do that

coopernetes added a commit to coopernetes/kube-role-gen that referenced this issue Feb 20, 2023
* new make target for running tests
* removed kubeval & added kubeconform.
  See: instrumenta/kubeval#268 (comment)
* use newer conftest install instructions
* fix version flag
coopernetes added a commit to coopernetes/kube-role-gen that referenced this issue Feb 20, 2023
* upgrade orderedmap to v2.2.0 to support generic
* gofmt to address go report card
* new functions for each step in role creation & add tests

remove internal pkgs, add GoDS

implement role gen, add docs, make and print version

rearrange main, use make in build workflow

[skip ci] fix gh badge, add pkg.go.dev

fix missing resources & failing tests, update CI

* new make target for running tests
* removed kubeval & added kubeconform.
  See: instrumenta/kubeval#268 (comment)
* use newer conftest install instructions
* fix version flag

make test & e2e separate, fix workflow

attempt to fix ci again

path issue

merge resources across matching API groups

* fixes regression. Necessary for the batch/v1 jobs resource to not be erased. Jobs are the only API resource
  that do not appear in alpha/beta groups where its companion
  resource, CronJob, does in fact exist in two groups (up until k8s v1.25).

 see: https://kubernetes.io/docs/reference/using-api/deprecation-guide/#v1-25

passing test, sort resource names
coopernetes added a commit to coopernetes/kube-role-gen that referenced this issue Feb 21, 2023
* upgrade orderedmap to v2.2.0 to support generic
* gofmt to address go report card
* new functions for each step in role creation & add tests

remove internal pkgs, add GoDS

implement role gen, add docs, make and print version

rearrange main, use make in build workflow

[skip ci] fix gh badge, add pkg.go.dev

fix missing resources & failing tests, update CI

* new make target for running tests
* removed kubeval & added kubeconform.
  See: instrumenta/kubeval#268 (comment)
* use newer conftest install instructions
* fix version flag

make test & e2e separate, fix workflow

attempt to fix ci again

path issue

merge resources across matching API groups

* fixes regression. Necessary for the batch/v1 jobs resource to not be erased. Jobs are the only API resource
  that do not appear in alpha/beta groups where its companion
  resource, CronJob, does in fact exist in two groups (up until k8s v1.25).

 see: https://kubernetes.io/docs/reference/using-api/deprecation-guide/#v1-25

passing test, sort resource names

empty commit
sgerrand added a commit to sgerrand/homebrew-brewfile that referenced this issue Dec 1, 2023
The `kubeval` package is no longer maintained, `kubeconform` was developed to replace it.

```
Error: kubeval has been disabled because it is not maintained upstream!
```
instrumenta/kubeval#268 (comment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants