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

feat: validate Promise pipelines #332

Open
ChunyiLyu opened this issue Jan 22, 2025 · 0 comments
Open

feat: validate Promise pipelines #332

ChunyiLyu opened this issue Jan 22, 2025 · 0 comments

Comments

@ChunyiLyu
Copy link
Member

ChunyiLyu commented Jan 22, 2025

Context

Workflow pipelines are not validated by Kratix webhook at Promise creation and update. Promises with invalid pipelines are being 'successfully applied by kratix. Users need to look at kratix logs to be able to find out what went wrong.

This story is about adding pipeline validation to our Promise validation webhook to provide faster feedback to our users about what went wrong.

Validation in scope for this issue is about identifying invalid pipelines that will prevent pipeline resources (jobs/rbac objects) being generated. When pipeline resources can be generated and created but pipeline fails to execute, that's not the problem we are trying to tackle here, for example a container that uses private image that cannot be pulled is not a concern for this issue.

Validation should be performed on all workflow types and actions, promise and resources, configure and delete.

Give a Promise with a workflow pipeline
When a container under `spec.containers has no container image or container name
This Promise fail to apply (create and update)

When the spec cannot generated into a Kubernetes Job
This Promise fail to apply (create and update)

When there is an unknown key specified under the pipeline spec
This Promise fail to apply (create and update)

When `spec.volumes` `spec.imagePullSecrets` or `spec.rbac` cannot be parsed by Kratix
This Promise fail to apply (create and update)
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

1 participant