micro: Runtime class name not being passed on update (v3.1.0)
micro version used: v3.1.0
- I create a new service called user on my local machine using:
micro new user
- I cd into the new service root folder:
cd user
- I deployed it to a remote Kubernetes cluster on GCP using:
micro run .
- I made some changes to my handlers
- I tried to redeploy the service using:
micro update .
The last step fails and the service never gets updated on Kubernetes.
The logs from the runtime (micro logs -f runtime
) shows this:
2021-02-28 19:41:49 file=handler/handler.go:474 level=info service=runtime Updating service user version latest source source://user:latest
2021-02-28 19:41:49 file=manager/util.go:51 level=info service=runtime Preparing to build user:latest
2021-02-28 19:41:49 file=manager/util.go:100 level=info service=runtime Build starting user:latest
2021-02-28 19:42:23 file=manager/util.go:105 level=info service=runtime Build finished user:latest <nil>
2021-02-28 19:42:23 file=manager/util.go:115 level=info service=runtime Uploading build user:latest
2021-02-28 19:42:24 file=kubernetes/kubernetes.go:383 level=error service=runtime Runtime failed to update deployment: {"kind":"Status","apiVersion":"v1","metadata":{},"status":"Failure","message":"Deployment.apps \"user-latest\" is invalid: spec.template.spec.runtimeClassName: Invalid value: \"\": a DNS-1123 subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character (e.g. 'example.com', regex used for validation is '[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*')","reason":"Invalid","details":{"name":"user-latest","group":"apps","kind":"Deployment","causes":[{"reason":"FieldValueInvalid","message":"Invalid value: \"\": a DNS-1123 subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character (e.g. 'example.com', regex used for validation is '[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*')","field":"spec.template.spec.runtimeClassName"}]},"code":422}
Looks like an empty runtimeClassName on update.
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 27 (12 by maintainers)
Tagged a release 3.1.1 with the proposed fix. You should see helm chart version micro-1.2.1 soon.