You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Namespace "pepr-demo" is invalid: metadata.annotations: Invalid value: "b9ea57fe-e4f9-55b1-9bdc-0dc6eeb49aa0.pepr.dev/hello pepr": name part must consist of alphanumeric characters, '-', '_' or '.', and must start and end with an alphanumeric character (e.g. 'MyName', or 'my.name', or '123-abc', regex used for validation is '([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]')
Steps to reproduce
Define the capability name with a space
exportconstHelloPepr=newCapability({name: "hello pepr",description: "A simple example capability to show how things work.",namespaces: ["pepr-demo","pepr-demo-2"],});
Create a mutation
k apply -f -<<EOFapiVersion: v1kind: Namespacemetadata:
name: pepr-demolabels:
keep-me: pleaseremove-me: pleaseEOFThe Namespace "pepr-demo" is invalid: metadata.annotations: Invalid value: "b9ea57fe-e4f9-55b1-9bdc-0dc6eeb49aa0.pepr.dev/hello pepr": name part must consist of alphanumeric characters, '-', '_' or '.', and must start and end with an alphanumeric character (e.g. 'MyName', or 'my.name', or '123-abc', regex used for validation is '([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]')
Expected result
Mutation annotation to be kubernetes safe
Actual Result
Visual Proof (screenshots, videos, text, etc)
Severity/Priority
Additional Context
Add any other context or screenshots about the technical debt here.
The text was updated successfully, but these errors were encountered:
## Description
Sanitizes the name that goes into the annotation
## Related Issue
Fixes#730
<!-- or -->
Relates to #
## Type of change
- [x] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Other (security config, docs update, etc)
## Checklist before merging
- [ ] Test, docs, adr added or updated as needed
- [ ] [Contributor Guide
Steps](https://docs.pepr.dev/main/contribute/contributor-guide/#submitting-a-pull-request)
followed
---------
Signed-off-by: Case Wylie <cmwylie19@defenseunicorns.com>
Environment
Mutation annotation needs sanitization
Steps to reproduce
Define the capability name with a space
Create a mutation
Expected result
Mutation annotation to be kubernetes safe
Actual Result
Visual Proof (screenshots, videos, text, etc)
Severity/Priority
Additional Context
Add any other context or screenshots about the technical debt here.
The text was updated successfully, but these errors were encountered: