From c25a540955008bc05a432e3aadae6480524192fc Mon Sep 17 00:00:00 2001 From: shucheng Date: Thu, 18 Oct 2018 17:58:53 +0800 Subject: [PATCH] update --- readme.md | 18 ++++++++-------- templates/istio/notary.gateway.yaml | 32 +++++++++++++++++++++++++++++ templates/istio/ui.gateway.yaml | 32 +++++++++++++++++++++++++++++ values.yaml | 3 +++ 4 files changed, 75 insertions(+), 10 deletions(-) create mode 100644 templates/istio/notary.gateway.yaml create mode 100644 templates/istio/ui.gateway.yaml diff --git a/readme.md b/readme.md index efb094c..b92d6ef 100644 --- a/readme.md +++ b/readme.md @@ -45,11 +45,6 @@ docker pull registry:2.6.2 && \ docker tag registry:2.6.2 registry-vpc.cn-qingdao.aliyuncs.com/wod/registry:2.6.2 && \ docker push registry-vpc.cn-qingdao.aliyuncs.com/wod/registry:2.6.2 -# nginx -docker pull nginx:1.15.2-alpine && \ -docker tag nginx:1.15.2-alpine registry-vpc.cn-qingdao.aliyuncs.com/wod/nginx:1.15.2-alpine && \ -docker push registry-vpc.cn-qingdao.aliyuncs.com/wod/nginx:1.15.2-alpine - # redis docker pull redis:4.0.1-alpine && \ docker tag redis:4.0.1-alpine registry-vpc.cn-qingdao.aliyuncs.com/wod/redis:4.0.1-alpine && \ @@ -69,7 +64,10 @@ externalDomain: harbor.wodcloud.local harborAdminPassword: "58772015" ingress: - enabled: true + enabled: false + +istio: + enabled: true adminserver: image: @@ -157,12 +155,12 @@ notary: enabled: true server: image: - repository: registry.cn-qingdao.aliyuncs.com/wod/notary-server - tag: 0.5.0 + repository: registry.cn-qingdao.aliyuncs.com/wod/notary-server-photon + tag: dev signer: image: - repository: registry.cn-qingdao.aliyuncs.com/wod/notary-signer - tag: 0.5.0 + repository: registry.cn-qingdao.aliyuncs.com/wod/notary-signer-photon + tag: dev ``` ## setup diff --git a/templates/istio/notary.gateway.yaml b/templates/istio/notary.gateway.yaml new file mode 100644 index 0000000..0086fbb --- /dev/null +++ b/templates/istio/notary.gateway.yaml @@ -0,0 +1,32 @@ +{{ if .Values.istio.enabled }} +apiVersion: networking.istio.io/v1alpha3 +kind: Gateway +metadata: + name: "{{ template "harbor.fullname" . }}"-notary +spec: + selector: + istio: ingressgateway # use istio default controller + servers: + - port: + number: 80 + name: http + protocol: HTTP + hosts: + - "{{ template "harbor.notaryFQDN" . }}" +--- +apiVersion: networking.istio.io/v1alpha3 +kind: VirtualService +metadata: + name: "{{ template "harbor.fullname" . }}"-notary +spec: + hosts: + - "{{ template "harbor.notaryFQDN" . }}" + gateways: + - "{{ template "harbor.fullname" . }}"-notary + http: + - route: + - destination: + host: {{ template "harbor.notaryServiceName" . }} + port: + number: 4443 +{{ end }} diff --git a/templates/istio/ui.gateway.yaml b/templates/istio/ui.gateway.yaml new file mode 100644 index 0000000..620d97b --- /dev/null +++ b/templates/istio/ui.gateway.yaml @@ -0,0 +1,32 @@ +{{ if .Values.istio.enabled }} +apiVersion: networking.istio.io/v1alpha3 +kind: Gateway +metadata: + name: "{{ template "harbor.fullname" . }}"-ui +spec: + selector: + istio: ingressgateway # use istio default controller + servers: + - port: + number: 80 + name: http + protocol: HTTP + hosts: + - "{{ .Values.externalDomain }}" +--- +apiVersion: networking.istio.io/v1alpha3 +kind: VirtualService +metadata: + name: "{{ template "harbor.fullname" . }}"-ui +spec: + hosts: + - "{{ .Values.externalDomain }}" + gateways: + - "{{ template "harbor.fullname" . }}"-ui + http: + - route: + - destination: + host: {{ template "harbor.fullname" . }}-ui + port: + number: 80 +{{ end }} diff --git a/values.yaml b/values.yaml index 15b50f8..0f0d81b 100644 --- a/values.yaml +++ b/values.yaml @@ -43,6 +43,9 @@ ingress: # be generated automatically by the chart if leave it empty secretName: "" +istio: + enabled: false + # The tag for Harbor docker images. harborImageTag: &harbor_image_tag dev -- 2.26.0