apiVersion: apps/v1
kind: Deployment
metadata:
  name: bittrader-order-scheduler
  labels:
    app: order-scheduler
    tier: backend
    probe: actuator
    gke: spot
spec:
  selector:
    matchLabels:
      app: order-scheduler
  template:
    metadata:
      labels:
        app: order-scheduler
        tier: backend
    spec:
      containers:
        - name: order-scheduler
          image: ghcr.io/ken-tunc/bittrader/bittrader-order-scheduler
          imagePullPolicy: Always
          ports:
            - containerPort: 8080
          env:
            - name: SPRING_PROFILES_ACTIVE
              value: prod
            - name: TZ
              valueFrom:
                configMapKeyRef:
                  name: bittrader-backend-config
                  key: time_zone
          resources:
            requests:
              memory: "512Mi"
              cpu: "250m"
            limits:
              memory: "1Gi"
              cpu: "500m"
