mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-16 15:25:18 +01:00
Merge pull request #5159 from reasonerjt/helm-chart-ingress-refinement
Add externalPort in values.yaml
This commit is contained in:
commit
05fd9c8836
@ -30,6 +30,14 @@ release: {{ .Release.Name }}
|
|||||||
app: "{{ template "harbor.name" . }}"
|
app: "{{ template "harbor.name" . }}"
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
|
{{- define "harbor.externalURL" -}}
|
||||||
|
{{- if .Values.externalPort -}}
|
||||||
|
{{- printf "%s:%s" .Values.externalDomain (toString .Values.externalPort) -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- .Values.externalDomain -}}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
{{/*
|
{{/*
|
||||||
Use *.domain.com as the Common Name in the certificate,
|
Use *.domain.com as the Common Name in the certificate,
|
||||||
so it can match Harbor service FQDN and Notary service FQDN.
|
so it can match Harbor service FQDN and Notary service FQDN.
|
||||||
|
@ -56,7 +56,7 @@ data:
|
|||||||
"auth": {
|
"auth": {
|
||||||
"type": "token",
|
"type": "token",
|
||||||
"options": {
|
"options": {
|
||||||
"realm": "https://{{ .Values.externalDomain }}/service/token",
|
"realm": "https://{{ template "harbor.externalURL" . }}/service/token",
|
||||||
"service": "harbor-notary",
|
"service": "harbor-notary",
|
||||||
"issuer": "harbor-token-issuer",
|
"issuer": "harbor-token-issuer",
|
||||||
"rootcertbundle": "/root.crt"
|
"rootcertbundle": "/root.crt"
|
||||||
|
@ -38,7 +38,7 @@ data:
|
|||||||
auth:
|
auth:
|
||||||
token:
|
token:
|
||||||
issuer: harbor-token-issuer
|
issuer: harbor-token-issuer
|
||||||
realm: "https://{{ .Values.externalDomain }}/service/token"
|
realm: "https://{{ template "harbor.externalURL" . }}/service/token"
|
||||||
rootcertbundle: /etc/registry/root.crt
|
rootcertbundle: /etc/registry/root.crt
|
||||||
service: harbor-registry
|
service: harbor-registry
|
||||||
|
|
||||||
|
@ -35,7 +35,7 @@ spec:
|
|||||||
- containerPort: 5000
|
- containerPort: 5000
|
||||||
- containerPort: 5001
|
- containerPort: 5001
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
{{- if not .Values.registry.objectStorage }}
|
{{- if and (not .Values.registry.objectStorage) .Values.persistence.enabled }}
|
||||||
- name: registry-data
|
- name: registry-data
|
||||||
mountPath: /var/lib/registry
|
mountPath: /var/lib/registry
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
@ -33,6 +33,9 @@ harborImageTag: &harbor_image_tag v1.5.0-chart-patch
|
|||||||
|
|
||||||
# The FQDN for Harbor service.
|
# The FQDN for Harbor service.
|
||||||
externalDomain: harbor.my.domain
|
externalDomain: harbor.my.domain
|
||||||
|
# externalPort is the Port for Harbor service, leave empty if the service is to be bound to
|
||||||
|
# port 80/443
|
||||||
|
externalPort: 32700
|
||||||
# If set to true, you don't need to set tlsCrt/tlsKey/caCrt, but must add
|
# If set to true, you don't need to set tlsCrt/tlsKey/caCrt, but must add
|
||||||
# Harbor FQDN as insecure-registries for your docker client.
|
# Harbor FQDN as insecure-registries for your docker client.
|
||||||
insecureRegistry: false
|
insecureRegistry: false
|
||||||
|
Loading…
Reference in New Issue
Block a user