apiVersion: apps/v1
kind: Deployment
metadata:
  name: crane-predictor
  labels:
    k8s-app: crane-predictor
spec:
  replicas: 1
  selector:
    matchLabels:
      k8s-app: crane-predictor
  strategy:
    rollingUpdate:
      maxSurge: 1
      maxUnavailable: 1
    type: RollingUpdate
  template:
    metadata:
      labels:
        k8s-app: crane-predictor
        label_qcloud_app: crane-predictor
    spec:
      serviceAccountName: crane-predictor
      restartPolicy: Always
      containers:
        - image: ccr.ccs.tencentyun.com/kube-orm/predictor:unknown
          name: crane-predictor
          command:
            - "/usr/local/bin/predictor"
          args:
            - "--prometheus-address=http://prometheus-service.monitoring.svc.cluster.local"
            - "--v=6"
          resources:
            requests:
              cpu: "200m"
              memory: "512M"
          imagePullPolicy: Always