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

Openshift existing resources won't merge route spec #29899

Closed
indiealexh opened this issue Dec 15, 2022 · 2 comments · Fixed by #29926
Closed

Openshift existing resources won't merge route spec #29899

indiealexh opened this issue Dec 15, 2022 · 2 comments · Fixed by #29926
Labels
area/kubernetes kind/bug Something isn't working
Milestone

Comments

@indiealexh
Copy link

indiealexh commented Dec 15, 2022

Describe the bug

The default Route resource created has no programmatic means to apply TLS config.
Upon reading https://quarkus.io/guides/deploying-to-kubernetes#using-existing-resources I assumed I could create an src/main/kubernetes/openshift.yml file like this:

apiVersion: route.openshift.io/v1
kind: Route
metadata:
  name: example-api
spec:
  tls:
    termination: edge
    insecureEdgeTerminationPolicy: Redirect

and it could generated something like this:

---
apiVersion: route.openshift.io/v1
kind: Route
metadata:
  annotations:
    app.openshift.io/vcs-url: <<unknown>>
    app.quarkus.io/commit-id: <<example>>
    app.quarkus.io/build-timestamp: <<example>>
  labels:
    app.openshift.io/runtime: quarkus
    app.kubernetes.io/version: 1.0.0
    app.kubernetes.io/name: example-api
    app.kubernetes.io/part-of: core
  name: example-api
spec:
  host: example-api.hostname.com
  port:
    targetPort: http
  tls:
    insecureEdgeTerminationPolicy: Redirect
    termination: edge
  to:
    kind: Service
    name: colony-legacy-api

But instead it omits everything it would normally generate except annotations and labels:

apiVersion: route.openshift.io/v1
kind: Route
metadata:
  annotations:
    app.openshift.io/vcs-url: <<unknown>>
    app.quarkus.io/commit-id: <<example>>
    app.quarkus.io/build-timestamp: <<example>>
  labels:
    app.openshift.io/runtime: quarkus
    app.kubernetes.io/version: 1.0.0
    app.kubernetes.io/name: example-api
    app.kubernetes.io/part-of: core
  name: example-api
spec:
  tls:
    insecureEdgeTerminationPolicy: Redirect
    termination: edge

Quarkus version or git rev

2.15.0

@indiealexh indiealexh added the kind/bug Something isn't working label Dec 15, 2022
@quarkus-bot
Copy link

quarkus-bot bot commented Dec 15, 2022

/cc @Sgitario(kubernetes), @geoand(kubernetes,openshift), @iocanel(kubernetes,openshift)

@Sgitario
Copy link
Contributor

This needs to be fixed first in Dekorate: dekorateio/dekorate#1112

Sgitario added a commit to Sgitario/dekorate that referenced this issue Dec 16, 2022
Sgitario added a commit to dekorateio/dekorate that referenced this issue Dec 16, 2022
@quarkus-bot quarkus-bot bot added this to the 2.16 - main milestone Dec 19, 2022
@gsmet gsmet modified the milestones: 2.16 - main, 2.15.1.Final Dec 20, 2022
gsmet pushed a commit to gsmet/quarkus that referenced this issue Dec 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/kubernetes kind/bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants