diff --git a/templates/userservice/userservice-deployment.yaml b/templates/userservice/userservice-deployment.yaml index f7f7ed8..1ca132d 100644 --- a/templates/userservice/userservice-deployment.yaml +++ b/templates/userservice/userservice-deployment.yaml @@ -27,10 +27,27 @@ spec: - name: wait-for-rocketchat image: busybox command: [ "sh", "-c", "until nc -z rocketchat 3000 > /dev/null; do echo Waiting for rocketchat.; sleep 5; done;" ] + {{- if .Values.global.site24x7Enabled }} - name: site24x7 image: site24x7/apminsight-javaagent:latest imagePullPolicy: IfNotPresent command: [ 'cp', '-r', '/opt/site24x7/.', '/home/apm' ] + volumeMounts: + - name: s247agent + mountPath: /home/apm + - name: replace-site24x7-key + image: busybox + command: [ "sh", "-c", "sed -i 's/^license.key=.*/license.key='\"$SITE247_LICENSE_KEY\"'/g' /home/apm/apminsight.conf" ] + volumeMounts: + - name: s247agent + mountPath: /home/apm + env: + - name: SITE247_LICENSE_KEY + valueFrom: + secretKeyRef: + key: SITE247_LICENSE_KEY + name: userservice-secret-{{ .Release.Name }}-env + {{- end }} containers: - env: - name: IDENTITY_OPENID_CONNECT_URL