Skip to content

Commit ceaf710

Browse files
committed
Skip unknown expose.type
This commit adjust the creation of the service of nginx. It will skip the creation of the service if the `expose.type` is set to an unknown value. One benefit of this change is that user can create the service to expose Harbor first, and deploy other components using the chart. Signed-off-by: Daniel Jiang <[email protected]>
1 parent 30af256 commit ceaf710

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ The following table lists the configurable parameters of the Harbor chart and th
8888
| Parameter | Description | Default |
8989
| --------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------- |
9090
| **Expose** |
91-
| `expose.type` | The way how to expose the service: `ingress`, `clusterIP`, `nodePort` or `loadBalancer` | `ingress` |
91+
| `expose.type` | The way how to expose the service: `ingress`, `clusterIP`, `nodePort` or `loadBalancer`, other values will be ignored and the creation of service will be skipped. | `ingress` |
9292
| `expose.tls.enabled` | Enable the tls or not | `true` |
9393
| `expose.ingress.controller` | The ingress controller type. Currently supports `default`, `gce` and `ncp` | `default` |
9494
| `expose.tls.secretName` | Fill the name of secret if you want to use your own TLS certificate and private key. The secret must contain keys named `tls.crt` and `tls.key` that contain the certificate and private key to use for TLS. The certificate and private key will be generated automatically if it is not set | |

templates/nginx/service.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{{- if ne .Values.expose.type "ingress" }}
1+
{{- if or (eq .Values.expose.type "clusterIP") (eq .Values.expose.type "nodePort") (eq .Values.expose.type "loadBalancer") }}
22
apiVersion: v1
33
kind: Service
44
metadata:

0 commit comments

Comments
 (0)