Skip to content

Commit

Permalink
Add support for specifying the hostname when using OpenShift.
Browse files Browse the repository at this point in the history
  • Loading branch information
smuda committed Nov 14, 2023
1 parent 3e86d39 commit e5ddcf4
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion kubernetes/blackduck/README.md
Expand Up @@ -128,7 +128,11 @@ You can access the Black Duck UI by https://${EXTERNAL_IP}

```bash
$ export SERVICE_TYPE=OpenShift
$ helm upgrade ${BD_NAME} synopsys/blackduck --namespace ${BD_NAME} --set exposedServiceType=${SERVICE_TYPE} --reuse-values
$ export HOST_NAME=blackduck.example.com
$ helm upgrade ${BD_NAME} synopsys/blackduck --namespace ${BD_NAME} \
--set exposedServiceType=${SERVICE_TYPE} \
--set route.hostname=${HOST_NAME} \
--reuse-values
```

you can use the following command to get the OpenShift routes
Expand Down
2 changes: 1 addition & 1 deletion kubernetes/blackduck/templates/webserver.yaml
Expand Up @@ -28,7 +28,7 @@ metadata:
name: {{ .Release.Name }}-blackduck
namespace: {{ .Release.Namespace }}
spec:
host: ""
host: "{{ .Values.route.hostname }}"
port:
targetPort: port-443
tls:
Expand Down
4 changes: 4 additions & 0 deletions kubernetes/blackduck/values.yaml
Expand Up @@ -27,6 +27,10 @@ exposedServiceType: NodePort
# custom port to expose the NodePort service on
exposedNodePort: ""

# The hostname for the OpenShift route. An empty hostname lets OpenShift autogenerate the hostname.
route:
hostname: ""

# enable Persistent Storage for containers
enablePersistentStorage: true
# it will apply to all PVC's storage class but it can be override at container level
Expand Down

0 comments on commit e5ddcf4

Please sign in to comment.