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

Update deployment.yaml - fix container #378

Closed
wants to merge 5 commits into from
Closed
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
16 changes: 6 additions & 10 deletions deployments/kubernetes/chart/forecastle/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,25 +31,21 @@ spec:
{{- toYaml . | nindent 8 }}
{{- end }}
containers:
- securityContext: {{- toYaml .Values.forecastle.container.securityContext | nindent 12 }}
- name: {{ template "forecastle.name" . }}
securityContext: {{- toYaml .Values.forecastle.container.securityContext | nindent 12 }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
securityContext: {{- toYaml .Values.forecastle.container.securityContext | nindent 12 }}
securityContext: {{- toYaml .Values.forecastle.container.securityContext | nindent 10 }}

env:
- name: KUBERNETES_NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata.namespace
image: "{{ .Values.forecastle.image.name }}:{{ .Values.forecastle.image.tag }}"
name: {{ template "forecastle.name" . }}
{{- if .Values.forecastle.deployment.resources }}
resources:
{{ toYaml .Values.forecastle.deployment.resources | indent 10 }}
{{- end }}
volumeMounts:
- name: {{ template "forecastle.name" . }}-config
mountPath: /etc/forecastle
{{- with .Values.forecastle.deployment.securityContext }}
securityContext:
{{- toYaml . | nindent 10 }}
{{- end }}
{{- if .Values.forecastle.openshiftOauthProxy.enabled }}
- name: oauth-proxy
image: "{{ default "stakater/oauth-proxy:v0.0.2" .Values.forecastle.openshiftOauthProxy.image }}"
Expand Down Expand Up @@ -77,6 +73,10 @@ spec:
{{ toYaml .Values.forecastle.openshiftOauthProxy.resources | indent 10 }}
{{- end }}
{{- end }}
{{- if .Values.forecastle.deployment.securityContext }}
securityContext:
{{- toYaml . | nindent 10 }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
{{- toYaml . | nindent 10 }}
{{- toYaml .Values.forecastle.deployment.securityContext | nindent 8 }}

{{- end }}
volumes:
- name: {{ template "forecastle.name" . }}-config
configMap:
Expand All @@ -87,10 +87,6 @@ spec:
secretName: openshift-oauth-proxy-tls
{{- end }}
serviceAccountName: {{ template "forecastle.name" . }}
{{- with .Values.forecastle.deployment.podSecurityContext }}
securityContext:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.forecastle.deployment.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
Expand Down
4 changes: 1 addition & 3 deletions deployments/kubernetes/manifests/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,13 @@ spec:
checksum/api-config: b4082837631aaa2678a872e391d8e09ed35c590f39203dd25526abeb874885e1
spec:
containers:
- securityContext:
{}
- name: forecastle
env:
- name: KUBERNETES_NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata.namespace
image: "stakater/forecastle:v1.0.127"
name: forecastle
volumeMounts:
- name: forecastle-config
mountPath: /etc/forecastle
Expand Down
Loading