Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions apps/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -385,6 +385,40 @@ EOF

<details><summary>HARBOR</summary>

### w/ INGRESS (DAGGER)

```bash
dagger call -m github.com/stuttgart-things/dagger/helm@v0.57.0 \
helmfile-operation \
--helmfile-ref "git::https://github.com/stuttgart-things/helm.git@apps/harbor.yaml.gotmpl" \
--operation apply \
--state-values "namespace=harbor,domain=idp.kubermatic.sva.dev,issuerName=letsencrypt-prod,storageClass=vsphere-csi,adminPassword=<HARBOR_PASSWORD>" \
--kube-config file://config.yaml \
--progress plain -vv
```

### w/ HTTPROUTE (GATEWAY API)

```bash
cat <<EOF > harbor.yaml
---
helmfiles:
- path: git::https://github.com/stuttgart-things/helm.git@apps/harbor.yaml.gotmpl
values:
- namespace: harbor
- hostname: harbor
- domain: 172.18.0.2.nip.io
- storageClass: standard
- adminPassword: <HARBOR_PASSWORD>
- deployHttpRoute: true
- gatewayName: cilium-gateway
- gatewayNamespace: default
EOF

helmfile template -f harbor.yaml # RENDER ONLY
helmfile apply -f harbor.yaml # APPLY HELMFILE
```

### w/ INGRESS + CERT (INGRESS ANNOTATION - CERT-MANAGER)

```bash
Expand Down
16 changes: 16 additions & 0 deletions apps/harbor.yaml.gotmpl
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ environments:
- issuerKind: ClusterIssuer
- issuerKindAnnotation: cluster-issuer
- createCertificateResource: false
- deployHttpRoute: false
- gatewayName: cilium-gateway
- gatewayNamespace: default
- certificates:
harbor:
hostname: {{ .Values.hostname }}
Expand Down Expand Up @@ -49,6 +52,19 @@ releases:
values:
- "values/harbor.values.yaml.gotmpl"

{{- if .Values.deployHttpRoute }}
- name: harbor-httproute
disableValidationOnInstall: true
installed: true
namespace: {{ .Values.namespace }}
chart: stuttgart-things/sthings-cluster
version: 0.3.20
needs:
- {{ .Values.namespace }}/harbor
values:
- "values/harbor-httproute.values.yaml.gotmpl"
{{- end }}

repositories:
- name: bitnami
url: https://charts.bitnami.com/bitnami
Expand Down
18 changes: 18 additions & 0 deletions apps/values/harbor-httproute.values.yaml.gotmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
customresources:
harbor-httproute:
apiVersion: gateway.networking.k8s.io/v1
kind: HTTPRoute
metadata:
name: harbor
namespace: {{ .Values.namespace }}
spec:
parentRefs:
- name: {{ .Values.gatewayName }}
namespace: {{ .Values.gatewayNamespace }}
hostnames:
- "{{ .Values.hostname }}.{{ .Values.domain }}"
rules:
- backendRefs:
- name: harbor
port: 443
6 changes: 6 additions & 0 deletions apps/values/harbor.values.yaml.gotmpl
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,11 @@ volumePermissions:



{{- if .Values.deployHttpRoute }}
exposureType: clusterIP
{{- else }}
exposureType: ingress
{{- end }}
service:
type: ClusterIP

Expand All @@ -54,6 +58,7 @@ ipFamily:
ipv4:
enabled: true

{{- if not .Values.deployHttpRoute }}
ingress:
core:
ingressClassName: {{ .Values.ingressClassName }}
Expand All @@ -71,6 +76,7 @@ ingress:
ingress.kubernetes.io/proxy-body-size: "0"
nginx.ingress.kubernetes.io/ssl-redirect: "true"
nginx.ingress.kubernetes.io/proxy-body-size: "0"
{{- end }}

{{- if .Values.enablePersistence }}
global:
Expand Down
Loading