diff --git a/k8s/app-exposer.yml b/k8s/app-exposer.yml index d7cb56c..fbd76b7 100644 --- a/k8s/app-exposer.yml +++ b/k8s/app-exposer.yml @@ -17,13 +17,13 @@ spec: affinity: podAntiAffinity: requiredDuringSchedulingIgnoredDuringExecution: - - labelSelector: - matchExpressions: - - key: de-app - operator: In - values: - - app-exposer - topologyKey: kubernetes.io/hostname + - labelSelector: + matchExpressions: + - key: de-app + operator: In + values: + - app-exposer + topologyKey: kubernetes.io/hostname restartPolicy: Always volumes: - name: localtime @@ -47,92 +47,81 @@ spec: - name: nats-services-creds secret: secretName: nats-services-creds - - name: nats-configuration - emptyDir: {} - initContainers: - - name: nats-configurator - image: harbor.cyverse.org/de/nats-configurator - env: - - name: NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - volumeMounts: - - name: nats-configuration - mountPath: /etc/cyverse/de/env containers: - - name: app-exposer - image: harbor.cyverse.org/de/app-exposer - resources: - requests: - cpu: "1m" - memory: "128Mi" - limits: - cpu: "100m" - memory: "256Mi" - args: - - --namespace - - "$(APP_EXPOSER_NAMESPACE)" - - --user-suffix - - "@$(USER_SUFFIX)" - - --log-level - - debug - env: - - name: APP_EXPOSER_NAMESPACE - valueFrom: - fieldRef: - fieldPath: metadata.namespace - - name: CLUSTER - value: "1" - - name: USER_SUFFIX - valueFrom: - secretKeyRef: - name: configs - key: USER_SUFFIX - - name: OTEL_TRACES_EXPORTER - valueFrom: - secretKeyRef: - name: configs - key: OTEL_TRACES_EXPORTER - - name: OTEL_EXPORTER_JAEGER_ENDPOINT - valueFrom: - secretKeyRef: - name: configs - key: OTEL_EXPORTER_JAEGER_HTTP_ENDPOINT - ports: - - name: listen-port - containerPort: 60000 - volumeMounts: - - name: localtime - mountPath: /etc/localtime - readOnly: true - - name: timezone - mountPath: /etc/timezone - subPath: timezone - - name: service-configs - mountPath: /etc/cyverse/de/configs - readOnly: true - - name: nats-client-tls - mountPath: /etc/nats/tls - readOnly: true - - name: nats-services-creds - mountPath: /etc/nats/creds - readOnly: true - - name: nats-configuration - mountPath: /etc/cyverse/de/env - readOnly: true - livenessProbe: - httpGet: - path: / - port: 60000 - initialDelaySeconds: 5 - periodSeconds: 5 - readinessProbe: - httpGet: - path: / - port: 60000 - initialDelaySeconds: 5 - periodSeconds: 5 + - name: app-exposer + image: harbor.cyverse.org/de/app-exposer + resources: + requests: + cpu: "1m" + memory: "128Mi" + limits: + cpu: "100m" + memory: "256Mi" + args: + - --namespace + - "$(APP_EXPOSER_NAMESPACE)" + - --user-suffix + - "@$(USER_SUFFIX)" + - --log-level + - debug + env: + - name: APP_EXPOSER_NAMESPACE + valueFrom: + fieldRef: + fieldPath: metadata.namespace + - name: CLUSTER + value: "1" + - name: USER_SUFFIX + valueFrom: + secretKeyRef: + name: configs + key: USER_SUFFIX + - name: OTEL_TRACES_EXPORTER + valueFrom: + secretKeyRef: + name: configs + key: OTEL_TRACES_EXPORTER + - name: OTEL_EXPORTER_JAEGER_ENDPOINT + valueFrom: + secretKeyRef: + name: configs + key: OTEL_EXPORTER_JAEGER_HTTP_ENDPOINT + - name: DISCOENV_NATS_CLUSTER + valueFrom: + secretKeyRef: + name: configs + key: NATS_URLS + ports: + - name: listen-port + containerPort: 60000 + volumeMounts: + - name: localtime + mountPath: /etc/localtime + readOnly: true + - name: timezone + mountPath: /etc/timezone + subPath: timezone + - name: service-configs + mountPath: /etc/cyverse/de/configs + readOnly: true + - name: nats-client-tls + mountPath: /etc/nats/tls + readOnly: true + - name: nats-services-creds + mountPath: /etc/nats/creds + readOnly: true + livenessProbe: + httpGet: + path: / + port: 60000 + initialDelaySeconds: 5 + periodSeconds: 5 + readinessProbe: + httpGet: + path: / + port: 60000 + initialDelaySeconds: 5 + periodSeconds: 5 --- apiVersion: v1 kind: Service @@ -165,4 +154,3 @@ spec: # - POST # - http://app-exposer/vice/apply-labels # restartPolicy: OnFailure -