-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ROX-23252: Add emailsender deployment (#1782)
* Add emailsender deployment * Add emailsender deployment * Update dp-terraform/helm/rhacs-terraform/templates/emailsender.yaml Co-authored-by: Johannes Malsam <[email protected]> * Add replicas --------- Co-authored-by: Johannes Malsam <[email protected]>
- Loading branch information
1 parent
cdc535a
commit 3a6bebf
Showing
3 changed files
with
90 additions
and
0 deletions.
There are no files selected for viewing
25 changes: 25 additions & 0 deletions
25
dp-terraform/helm/rhacs-terraform/templates/emailsender-rbac.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{{- if eq .Values.emailsender.enabled false }} | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
name: emailsender | ||
namespace: {{ .Release.Namespace }} | ||
--- | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: ClusterRoleBinding | ||
metadata: | ||
name: {{ printf "%s-%s" "emailsender-rb" .Release.Namespace }} | ||
roleRef: | ||
apiGroup: rbac.authorization.k8s.io | ||
kind: ClusterRole | ||
name: emailsender-role | ||
subjects: | ||
- kind: ServiceAccount | ||
name: emailsender | ||
namespace: {{ .Release.Namespace }} | ||
--- | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: ClusterRole | ||
metadata: | ||
name: emailsender-role | ||
{{- end }} |
46 changes: 46 additions & 0 deletions
46
dp-terraform/helm/rhacs-terraform/templates/emailsender.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
{{- if eq .Values.emailsender.enabled false }} | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: emailsender | ||
namespace: {{ .Release.Namespace }} | ||
labels: | ||
app: emailsender | ||
spec: | ||
replicas: {{ .Values.emailsender.replicas }} | ||
selector: | ||
matchLabels: | ||
app: emailsender | ||
strategy: | ||
type: RollingUpdate | ||
template: | ||
metadata: | ||
labels: | ||
app: emailsender | ||
spec: | ||
serviceAccountName: emailsender | ||
containers: | ||
- name: emailsender | ||
image: "{{ .Values.emailsender.image.repo }}:{{ .Values.emailsender.image.tag }}" | ||
imagePullPolicy: IfNotPresent | ||
command: | ||
- /usr/local/bin/emailsender | ||
env: | ||
- name: CLUSTER_ID | ||
value: {{ .Values.emailsender.clusterId }} | ||
- name: CLUSTER_NAME | ||
value: {{ .Values.emailsender.clusterName }} | ||
- name: ENVIRONMENT | ||
value: {{ .Values.emailsender.environment }} | ||
ports: | ||
- name: monitoring | ||
containerPort: 9090 | ||
- name: server | ||
containerPort: 8080 | ||
resources: | ||
limits: | ||
memory: {{ .Values.emailsender.resources.limits.memory | quote }} | ||
requests: | ||
cpu: {{ .Values.emailsender.resources.requests.cpu | quote }} | ||
memory: {{ .Values.emailsender.resources.requests.memory | quote }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters