Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add lifecycle to core dpl #1739

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
672 changes: 340 additions & 332 deletions README.md

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions templates/core/core-dpl.yaml
Expand Up @@ -85,6 +85,10 @@ spec:
port: {{ template "harbor.core.containerPort" . }}
failureThreshold: 2
periodSeconds: 10
{{- with .Values.core.lifecycle }}
lifecycle:
{{ toYaml . | indent 10 }}
{{- end }}
envFrom:
- configMapRef:
name: "{{ template "harbor.core" . }}"
Expand Down
4 changes: 4 additions & 0 deletions templates/exporter/exporter-dpl.yaml
Expand Up @@ -72,6 +72,10 @@ spec:
port: {{ .Values.metrics.exporter.port }}
initialDelaySeconds: 30
periodSeconds: 10
{{- with .Values.exporter.lifecycle }}
lifecycle:
{{ toYaml . | indent 10 }}
{{- end }}
args: ["-log-level", "{{ .Values.logLevel }}"]
envFrom:
- configMapRef:
Expand Down
4 changes: 4 additions & 0 deletions templates/jobservice/jobservice-dpl.yaml
Expand Up @@ -81,6 +81,10 @@ spec:
port: {{ template "harbor.jobservice.containerPort" . }}
initialDelaySeconds: 20
periodSeconds: 10
{{- with .Values.jobservice.lifecycle }}
lifecycle:
{{ toYaml . | indent 10 }}
{{- end }}
{{- if .Values.jobservice.resources }}
resources:
{{ toYaml .Values.jobservice.resources | indent 10 }}
Expand Down
4 changes: 4 additions & 0 deletions templates/nginx/deployment.yaml
Expand Up @@ -81,6 +81,10 @@ spec:
port: {{ .port }}
initialDelaySeconds: 1
periodSeconds: 10
{{- with .Values.nginx.lifecycle }}
lifecycle:
{{ toYaml . | indent 10 }}
{{- end }}
{{- if .Values.nginx.resources }}
resources:
{{ toYaml .Values.nginx.resources | indent 10 }}
Expand Down
4 changes: 4 additions & 0 deletions templates/portal/deployment.yaml
Expand Up @@ -83,6 +83,10 @@ spec:
port: {{ template "harbor.portal.containerPort" . }}
initialDelaySeconds: 1
periodSeconds: 10
{{- with .Values.portal.lifecycle }}
lifecycle:
{{ toYaml . | indent 10 }}
{{- end }}
ports:
- containerPort: {{ template "harbor.portal.containerPort" . }}
volumeMounts:
Expand Down
4 changes: 4 additions & 0 deletions templates/redis/statefulset.yaml
Expand Up @@ -58,6 +58,10 @@ spec:
port: 6379
initialDelaySeconds: 1
periodSeconds: 10
{{- with .Values.redis.internal.lifecycle }}
lifecycle:
{{ toYaml . | indent 10 }}
{{- end }}
{{- if .Values.redis.internal.resources }}
resources:
{{ toYaml .Values.redis.internal.resources | indent 10 }}
Expand Down
8 changes: 8 additions & 0 deletions templates/registry/registry-dpl.yaml
Expand Up @@ -84,6 +84,10 @@ spec:
port: {{ template "harbor.registry.containerPort" . }}
initialDelaySeconds: 1
periodSeconds: 10
{{- with .Values.registry.registry.lifecycle }}
lifecycle:
{{ toYaml . | indent 10 }}
{{- end }}
{{- if .Values.registry.registry.resources }}
resources:
{{ toYaml .Values.registry.registry.resources | indent 10 }}
Expand Down Expand Up @@ -223,6 +227,10 @@ spec:
port: {{ template "harbor.registryctl.containerPort" . }}
initialDelaySeconds: 1
periodSeconds: 10
{{- with .Values.registry.controller.lifecycle }}
lifecycle:
{{ toYaml . | indent 10 }}
{{- end }}
{{- if .Values.registry.controller.resources }}
resources:
{{ toYaml .Values.registry.controller.resources | indent 10 }}
Expand Down
4 changes: 4 additions & 0 deletions templates/trivy/trivy-sts.yaml
Expand Up @@ -164,6 +164,10 @@ spec:
periodSeconds: 10
successThreshold: 1
failureThreshold: 3
{{- with .Values.trivy.lifecycle }}
lifecycle:
{{ toYaml . | indent 10 }}
{{- end }}
resources:
{{ toYaml .Values.trivy.resources | indent 12 }}
{{- if or (or .Values.internalTLS.enabled .Values.caBundleSecretName) (or (not .Values.persistence.enabled) $trivy.existingClaim) }}
Expand Down
10 changes: 10 additions & 0 deletions values.yaml
Expand Up @@ -497,6 +497,7 @@ nginx:
extraEnvVars: []
nodeSelector: {}
tolerations: []
lifecycle: {}
affinity: {}
# Spread Pods across failure-domains like regions, availability zones or nodes
topologySpreadConstraints: []
Expand Down Expand Up @@ -528,6 +529,7 @@ portal:
extraEnvVars: []
nodeSelector: {}
tolerations: []
lifecycle: {}
affinity: {}
# Spread Pods across failure-domains like regions, availability zones or nodes
topologySpreadConstraints: []
Expand Down Expand Up @@ -565,6 +567,7 @@ core:
extraEnvVars: []
nodeSelector: {}
tolerations: []
lifecycle: {}
affinity: {}
# Spread Pods across failure-domains like regions, availability zones or nodes
topologySpreadConstraints: []
Expand Down Expand Up @@ -641,6 +644,7 @@ jobservice:
extraEnvVars: []
nodeSelector: {}
tolerations: []
lifecycle : {}
affinity: {}
# Spread Pods across failure-domains like regions, availability zones or nodes
topologySpreadConstraints:
Expand Down Expand Up @@ -688,6 +692,7 @@ registry:
# requests:
# memory: 256Mi
# cpu: 100m
lifecycle: {}
extraEnvVars: []
controller:
image:
Expand All @@ -697,6 +702,7 @@ registry:
# requests:
# memory: 256Mi
# cpu: 100m
lifecycle: {}
extraEnvVars: []
# set the service account to be used, default if left empty
serviceAccountName: ""
Expand All @@ -706,6 +712,7 @@ registry:
revisionHistoryLimit: 10
nodeSelector: {}
tolerations: []
lifecycle: {}
affinity: {}
# Spread Pods across failure-domains like regions, availability zones or nodes
topologySpreadConstraints: []
Expand Down Expand Up @@ -784,6 +791,7 @@ trivy:
nodeSelector: {}
tolerations: []
affinity: {}
lifecycle: {}
# Spread Pods across failure-domains like regions, availability zones or nodes
topologySpreadConstraints: []
# - maxSkew: 1
Expand Down Expand Up @@ -937,6 +945,7 @@ redis:
extraEnvVars: []
nodeSelector: {}
tolerations: []
lifecycle: {}
affinity: {}
## The priority class to run the pod as
priorityClassName:
Expand Down Expand Up @@ -996,6 +1005,7 @@ exporter:
podLabels: {}
nodeSelector: {}
tolerations: []
lifecycle: {}
affinity: {}
# Spread Pods across failure-domains like regions, availability zones or nodes
topologySpreadConstraints: []
Expand Down