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
If you create a branch that ends with a - and get Lagoon to build that, it currently does not work.
To Reproduce
Steps to reproduce the behavior:
Create branch that ends in -
Push branch
Notice Lagoon will never build it, the deployment will be stuck in new forever until being cancelled
Expected behavior
Lagoon should make the deployment work irrespective of the characters in a branch name. If it is a valid git branch name, then it should work.
Logs
Seen in lagoon-remote-insights-remote
1.6788638738456466e+09 ERROR Reconciler error {"controller": "lagoonbuild", "controllerGroup": "crd.lagoon.sh", "controllerKind": "LagoonBuild", "LagoonBuild": {"name":"lagoon-build-b7jgtf","namespace":"lagoon"}, "namespace": "lagoon", "name": "lagoon-build-b7jgtf", "reconcileID": "efad296e-cbe1-4eb1-b87f-e3c2fa017a30", "error": "There was an error creating the namespace. Error was: Namespace \"example-feature-fixed-css-\" is invalid: [metadata.name: Invalid value: \"example-feature-fixed-css-\": a lowercase RFC 1123 label must consist of lower case alphanumeric characters or '-', and must start and end with an alphanumeric character (e.g. 'my-name', or '123-abc', regex used for validation is '[a-z0-9]([-a-z0-9]*[a-z0-9])?'), metadata.labels: Invalid value: \"feature-fixed-css-\": a valid label must be an empty string or consist of alphanumeric characters, '-', '_' or '.', and must start and end with an alphanumeric character (e.g. 'MyValue', or 'my_value', or '12345', regex used for validation is '(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?'), metadata.labels: Invalid value: \"example-feature-fixed-css-\": a valid label must be an empty string or consist of alphanumeric characters, '-', '_' or '.', and must start and end with an alphanumeric character (e.g. 'MyValue', or 'my_value', or '12345', regex used for validation is '(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?')]"}
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).reconcileHandler
/go/pkg/mod/sigs.k8s.io/[email protected]/pkg/internal/controller/controller.go:326
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).processNextWorkItem
/go/pkg/mod/sigs.k8s.io/[email protected]/pkg/internal/controller/controller.go:273
sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func2.2
/go/pkg/mod/sigs.k8s.io/[email protected]/pkg/internal/controller/controller.go:234
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
hmm, in order to handle this, we'd have to append/remove a character to the branch name where it's used as a label (and potentially anywhere else RFC1123 kicks in)
hmm, in order to handle this, we'd have to append/remove a character to the branch name where it's used as a label (and potentially anywhere else RFC1123 kicks in)
Other issues are that we do similar makesafe-ing in other code bases that we need to consider. The remote-controller has the final say in what namespace is created though
Describe the bug
If you create a branch that ends with a
-
and get Lagoon to build that, it currently does not work.To Reproduce
Steps to reproduce the behavior:
-
new
forever until being cancelledExpected behavior
Lagoon should make the deployment work irrespective of the characters in a branch name. If it is a valid git branch name, then it should work.
Logs
Seen in
lagoon-remote-insights-remote
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: