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

Deploy to production #62

Merged
merged 1 commit into from
Nov 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,40 @@ Make sure to provide the names for the required config maps while building the i
-Dquarkus.openshift.config-map-volumes.app-config.config-map-name=<your-config-map-name> \
----

== Route configuration

We are not adding a route as part of the build since setting the path is currently unsupported.
Create a route either with `oc` or through a UI using the OpenShift console.
Make sure to set the next spec properties:

[source,yaml]
----
spec:
host: your-host.smth
path: /path-to-use
to:
kind: Service
name: your-replicate-jira-service-name
port:
targetPort: http
tls:
termination: edge
insecureEdgeTerminationPolicy: Redirect
wildcardPolicy: None
----

Note that certificates are not provided explicitly. To fully enable https and finish route configuration
add the following annotations to the route:

[source,yaml]
----
# will mark the resource as such that certificates will be generated for it:
# see https://github.com/tnozicka/openshift-acme/#enabling-acme-certificates-for-your-object
kubernetes.io/tls-acme: 'true'
# Set the target to root so that the path `/path-to-use` is not passed to the service:
haproxy.router.openshift.io/rewrite-target: /
----

== Management endpoints

There are management endpoints to sync particular issues/comments.
Expand Down
14 changes: 5 additions & 9 deletions src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,11 @@ quarkus.openshift.startup-probe.failure-threshold=48
# Declare the management port on the service
quarkus.openshift.ports."management".container-port=9000
quarkus.openshift.ports."management".host-port=90
# Add routes:
quarkus.openshift.route.host=infra.hibernate.org
quarkus.openshift.route.path=/replicate-jira
# Use a rewrite target so that the request go to the app root and the app handles the remaining path
# otherwise the app will end up receiving the path starting with `quarkus.openshift.route.path` (see ^)
# which it has no idea how to handle:
quarkus.openshift.route.annotations."haproxy.router.openshift.io/rewrite-target"=/
quarkus.openshift.route.expose=true
quarkus.openshift.route.target-port=http
# Routes:
# we disable routes in the build and add them manually, since setting path is currently unavailable.
# See README for details on adding a route.
quarkus.openshift.route.expose=false

## Route TLS configuration:
quarkus.openshift.route.tls.termination=edge
quarkus.openshift.route.tls.insecure-edge-termination-policy=Redirect
Expand Down