iac/rmk/apps/projects/deployment-projects-frontend-static.yaml
2026-11-17 19:12:41 +03:00

92 lines
2.4 KiB
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
name: projects-frontend-static
labels:
app: projects-frontend-static
service: frontend
namespace: projects
spec:
replicas: 2
revisionHistoryLimit: 10
selector:
matchLabels:
app: projects-frontend-static
template:
metadata:
labels:
app: projects-frontend-static
service: frontend
annotations:
proxy.istio.io/config: |
tracing:
sampling: 100
zipkin:
address: signoz-otel-collector-external.signoz.svc.cluster.local:9411
custom_tags:
k8s.pod.name:
environment:
name: POD_NAME
k8s.namespace.name:
environment:
name: POD_NAMESPACE
k8s.pod.ip:
environment:
name: INSTANCE_IP
traffic.sidecar.istio.io/excludeOutboundPorts: 4317,4318,9411
spec:
imagePullSecrets:
- name: regcred
nodeSelector:
dedicated: frontend
tolerations:
- key: dedicated
operator: Equal
value: frontend
effect: NoSchedule
containers:
- name: frontend
image: cr.yandex/crp3ccidau046kdj8g9q/project-frontend-app:latest
imagePullPolicy: IfNotPresent
ports:
- name: http
containerPort: 80
protocol: TCP
livenessProbe:
httpGet:
path: /ping
port: 80
initialDelaySeconds: 10
periodSeconds: 60
timeoutSeconds: 1
successThreshold: 1
failureThreshold: 10
readinessProbe:
httpGet:
path: /ping
port: 80
initialDelaySeconds: 10
periodSeconds: 30
timeoutSeconds: 1
successThreshold: 1
failureThreshold: 20
env:
- name: K8S_POD_UID
valueFrom:
fieldRef:
fieldPath: metadata.uid
- name: K8S_POD_NAME
valueFrom:
fieldRef:
fieldPath: metadata.name
- name: K8S_NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata.namespace
- name: OTEL_RESOURCE_ATTRIBUTES
value: k8s.pod.uid=$(K8S_POD_UID),k8s.pod.name=$(K8S_POD_NAME),k8s.namespace.name=$(K8S_NAMESPACE)
resources:
requests:
memory: 100Mi
cpu: 25m