Skip to content

Commit

Permalink
Merge pull request #51 from port-labs/PORT-5613-ocean-chart
Browse files Browse the repository at this point in the history
Added pod SCC and container SCC, rollout strategy and resource to ocean
  • Loading branch information
MatanHeledPort authored Dec 21, 2023
2 parents ec8c444 + b77b21e commit 0392a30
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 8 deletions.
2 changes: 2 additions & 0 deletions charts/port-agent/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ spec:
name: {{ include "port-agent.secretName" . }}
{{- end }}
resources:
{{- if .Values.resources }}
{{- toYaml .Values.resources | nindent 12 }}
{{- end }}
volumeMounts:
{{- if .Values.controlThePayloadConfig }}
- mountPath: /app/control_the_payload_config.json
Expand Down
2 changes: 0 additions & 2 deletions charts/port-agent/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ containerSecurityContext: {}
# runAsUser: 1001
# allowPrivilegeEscalation: false



rolloutStrategy: "Recreate"

resources:
Expand Down
2 changes: 1 addition & 1 deletion charts/port-ocean/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: port-ocean
description: A Helm chart for Port Ocean integrations
type: application
version: 0.1.11
version: 0.1.12
appVersion: "0.1.0"
home: https://getport.io/
sources:
Expand Down
19 changes: 16 additions & 3 deletions charts/port-ocean/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@ kind: Deployment
metadata:
name: {{ include "port-ocean.deploymentName" . }}
spec:
strategy:
type: {{ .Values.rolloutStrategy | default "Recreate" }}
securityContext:
{{- if .Values.podSecurityContext }}
{{- toYaml .Values.podSecurityContext | nindent 4 }}
{{- end }}
replicas: 1
selector:
matchLabels:
Expand All @@ -20,15 +26,22 @@ spec:
{{- end }}
image: ghcr.io/port-labs/port-ocean-{{ .Values.integration.type }}:{{ .Values.integration.version | default "latest" }}
{{- if .Values.service.enabled }}
securityContext:
{{- if .Values.containerSecurityContext }}
{{- toYaml .Values.containerSecurityContext | nindent 10 }}
{{- end }}
ports:
- containerPort: {{.Values.service.port}}
protocol: TCP
{{- end }}
{{- if .Values.selfSignedCertificate.enabled }}
env:
{{- if .Values.selfSignedCertificate.enabled }}
- name: SSL_CERT_FILE
value: /etc/ssl/certs/ca-certificates.crt
{{- end }}
{{- with .Values.extraEnv }}
{{- toYaml . | nindent 10 }}
{{- end }}
envFrom:
- configMapRef:
name: {{ include "port-ocean.configMapName" . }}
Expand Down Expand Up @@ -64,8 +77,8 @@ spec:
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.resources }}
resources:
{{- toYaml . | nindent 8 }}
{{- if .Values.resources }}
{{- toYaml .Values.resources | nindent 8 }}
{{- end }}

26 changes: 24 additions & 2 deletions charts/port-ocean/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,33 @@ port:

podAnnotations: {}

extraEnv:
# Example
# - name: HTTPS_PROXY
# value: http://myproxy.com

podSecurityContext: {}
# Example
# runAsGroup: 1001
# runAsUser: 1001
# fsGroup: 1001
# fsGroupChangePolicy: "OnRootMismatch"
containerSecurityContext: {}
# Example
# runAsGroup: 1001
# runAsUser: 1001
# allowPrivilegeEscalation: false

rolloutStrategy: "Recreate"

securityContext: {}
resources:
requests:
memory: "512Mi"
cpu: "200m"
limits:
memory: "1024Mi"
cpu: "500m"

resources: {}

nodeSelector: {}

Expand Down

0 comments on commit 0392a30

Please sign in to comment.