Skip to content

KService name validation should follow the k8s service restrictions #2942

@rgregg

Description

@rgregg

Related to issue #2941, we shouldn't allow the names of ksvc objects to not meet the requirements of the underlying k8s service that gets created from the name of the ksvc. When creating or updating a ksvc, we should validate that the name meets the requirements:

The Service "3dryan-render-demo" is invalid: metadata.name: Invalid value: "3dryan-render-demo": a DNS-1035 label must consist of lower case alphanumeric characters or '-', start with an alphabetic character, and end with an alphanumeric character (e.g. 'my-name',  or 'abc-123', regex used for validation is '[a-z]([-a-z0-9]*[a-z0-9])?')

Metadata

Metadata

Assignees

Labels

area/APIAPI objects and controllerskind/bugCategorizes issue or PR as related to a bug.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions