Created
November 4, 2022 18:15
-
-
Save SergK/01a06431819187004889d5e2dfe9e6d4 to your computer and use it in GitHub Desktop.
ReportPortal OpenShift Routing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
kind: ConfigMap | |
metadata: | |
name: gateway-config | |
namespace: report-portal | |
apiVersion: v1 | |
data: | |
traefik-dynamic-config.yml: | | |
http: | |
middlewares: | |
strip-ui: | |
stripPrefix: | |
prefixes: | |
- "/ui" | |
forceSlash: false | |
strip-api: | |
stripPrefix: | |
prefixes: | |
- "/api" | |
forceSlash: false | |
strip-uat: | |
stripPrefix: | |
prefixes: | |
- "/uat" | |
forceSlash: false | |
routers: | |
index-router: | |
rule: "Path(`/`)" | |
service: "index" | |
ui-router: | |
rule: "PathPrefix(`/ui`)" | |
middlewares: | |
- strip-ui | |
service: "ui" | |
uat-router: | |
rule: "PathPrefix(`/uat`)" | |
middlewares: | |
- strip-uat | |
service: "uat" | |
api-router: | |
rule: "PathPrefix(`/api`)" | |
middlewares: | |
- strip-api | |
service: "api" | |
services: | |
uat: | |
loadBalancer: | |
servers: | |
- url: "http://report-portal-reportportal-uat:9999/" | |
index: | |
loadBalancer: | |
servers: | |
- url: "http://report-portal-reportportal-index:8080/" | |
api: | |
loadBalancer: | |
servers: | |
- url: "http://report-portal-reportportal-api:8585/" | |
ui: | |
loadBalancer: | |
servers: | |
- url: "http://report-portal-reportportal-ui:8080/" | |
traefik.yml: | | |
entryPoints: | |
http: | |
address: ":8081" | |
metrics: | |
address: ":8082" | |
metrics: | |
prometheus: | |
entryPoint: metrics | |
addEntryPointsLabels: true | |
addServicesLabels: true | |
buckets: | |
- 0.1 | |
- 0.3 | |
- 1.2 | |
- 5.0 | |
providers: | |
file: | |
filename: /etc/traefik/traefik-dynamic-config.yml | |
--- | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
labels: | |
app: reportportal | |
name: gateway | |
namespace: report-portal | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
component: gateway | |
template: | |
metadata: | |
labels: | |
component: gateway | |
spec: | |
containers: | |
- image: quay.io/waynesun09/traefik:2.3.6 | |
name: traefik | |
ports: | |
- containerPort: 8080 | |
protocol: TCP | |
resources: {} | |
volumeMounts: | |
- mountPath: /etc/traefik/ | |
name: config | |
readOnly: true | |
volumes: | |
- name: config | |
configMap: | |
defaultMode: 420 | |
name: gateway-config | |
--- | |
kind: Route | |
apiVersion: route.openshift.io/v1 | |
metadata: | |
labels: | |
app: reportportal | |
name: reportportal | |
namespace: report-portal | |
spec: | |
host: report-portal.<CLUSTER_DOMAIN> | |
port: | |
targetPort: http | |
tls: | |
insecureEdgeTerminationPolicy: Redirect | |
termination: edge | |
to: | |
kind: Service | |
name: gateway | |
weight: 100 | |
wildcardPolicy: None | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
labels: | |
app: reportportal | |
component: gateway | |
name: gateway | |
namespace: report-portal | |
spec: | |
ports: | |
# use 8081 to allow for usage of the dashboard which is on port 8080 | |
- name: http | |
port: 8081 | |
protocol: TCP | |
targetPort: 8081 | |
selector: | |
component: gateway | |
sessionAffinity: None | |
type: ClusterIP |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment