blob: aed7ba011ae4925ebb885d3a6159654d49bbbb32 [file] [log] [blame]
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: autoroll-be-skia-skiabot-test-autoroll
spec:
serviceName: "autoroll-be-skia-skiabot-test-autoroll"
replicas: 1
selector:
matchLabels:
app: autoroll-be-skia-skiabot-test-autoroll
updateStrategy:
type: RollingUpdate
template:
metadata:
labels:
app: autoroll-be-skia-skiabot-test-autoroll # Pod template's label selector
annotations:
prometheus.io.scrape: "true"
prometheus.io.port: "20000"
spec:
automountServiceAccountToken: false
securityContext:
runAsUser: 2000 # aka skia
fsGroup: 2000 # aka skia
containers:
- name: autoroll-be-skia-skiabot-test-autoroll
image: gcr.io/skia-public/autoroll-be:2019-10-01T16_39_30Z-borenet-ad41711-clean
args:
- "--logtostderr"
- "--config=eyJjaGlsZE5hbWUiOiJTa2lhIiwiY29udGFjdHMiOlsiYm9yZW5ldEBnb29nbGUuY29tIl0sImlzSW50ZXJuYWwiOmZhbHNlLCJwYXJlbnROYW1lIjoiU2tpYWJvdCBUZXN0IiwicGFyZW50V2F0ZXJmYWxsIjoiaHR0cHM6Ly9zdGF0dXMtc3RhZ2luZy5za2lhLm9yZy9yZXBvL3NraWFib3QtdGVzdCIsInJvbGxlck5hbWUiOiJza2lhLXNraWFib3QtdGVzdC1hdXRvcm9sbCIsInNlcnZpY2VBY2NvdW50Ijoic2tpYS1hdXRvcm9sbEBza2lhLXB1YmxpYy5pYW0uZ3NlcnZpY2VhY2NvdW50LmNvbSIsInNoZXJpZmYiOlsiYm9yZW5ldEBnb29nbGUuY29tIl0sImdlcnJpdCI6eyJ1cmwiOiJodHRwczovL3NraWEtcmV2aWV3Lmdvb2dsZXNvdXJjZS5jb20iLCJwcm9qZWN0Ijoic2tpYWJvdC10ZXN0IiwiY29uZmlnIjoiY2hyb21pdW0ifSwiZnJlZVR5cGVSZXBvTWFuYWdlciI6bnVsbCwibm9DaGVja291dERFUFNSZXBvTWFuYWdlciI6eyJjaGlsZEJyYW5jaCI6Im1hc3RlciIsImNoaWxkUGF0aCI6InNraWEiLCJwYXJlbnRCcmFuY2giOiJtYXN0ZXIiLCJjaGlsZFJldkxpbmtUbXBsIjoiaHR0cHM6Ly9za2lhLmdvb2dsZXNvdXJjZS5jb20vc2tpYS5naXQvKy8lcyIsImNvbW1pdE1zZ1RtcGwiOiIiLCJwYXJlbnRSZXBvIjoiaHR0cHM6Ly9za2lhLmdvb2dsZXNvdXJjZS5jb20vc2tpYWJvdC10ZXN0LmdpdCIsImNoaWxkUmVwbyI6Imh0dHBzOi8vc2tpYS5nb29nbGVzb3VyY2UuY29tL3NraWEuZ2l0IiwiaW5jbHVkZUJ1Z3MiOmZhbHNlLCJpbmNsdWRlTG9nIjp0cnVlLCJ0cmFuc2l0aXZlRGVwcyI6bnVsbH0sImt1YmVybmV0ZXMiOnsiY3B1IjoiMSIsIm1lbW9yeSI6IjJHaSIsImRpc2siOiIifSwibWF4Um9sbEZyZXF1ZW5jeSI6IjBtIiwibm90aWZpZXJzIjpbeyJtc2dUeXBlV2hpdGVsaXN0IjpbImxhc3QgbiBmYWlsZWQiXSwibW9ub3JhaWwiOnsicHJvamVjdCI6InNraWEiLCJvd25lciI6ImJvcmVuZXRAZ29vZ2xlLmNvbSIsImNjIjpbInJtaXN0cnlAZ29vZ2xlLmNvbSJdLCJjb21wb25lbnRzIjpbIkF1dG9Sb2xsIl19fV0sInN1cHBvcnRzTWFudWFsUm9sbHMiOnRydWV9"
- "--email_creds=/var/secrets/autoroll-email-creds"
- "--firestore_instance=production"
- "--port=:8000"
- "--prom_port=:20000"
- "--recipes_cfg=/usr/local/share/autoroll/recipes.cfg"
- "--workdir=/tmp"
- "--chat_webhooks_file=/etc/notifier-chat-config/chat_config.txt"
ports:
- containerPort: 8000
- containerPort: 20000
volumeMounts:
- name: autoroll-be-skia-autoroll-sa
mountPath: /var/secrets/google
- name: autoroll-email-creds
mountPath: /var/secrets/autoroll-email-creds
- name: notifier-chat-config
mountPath: /etc/notifier-chat-config/
env:
- name: GOOGLE_APPLICATION_CREDENTIALS
value: /var/secrets/google/key.json
- name: TMPDIR
value: /tmp
resources:
limits:
memory: "2Gi"
cpu: 1
readinessProbe:
httpGet:
path: /healthz
port: 8000
initialDelaySeconds: 30
periodSeconds: 30
failureThreshold: 10
volumes:
- name: autoroll-be-skia-autoroll-sa
secret:
secretName: skia-autoroll
- name: autoroll-email-creds
secret:
secretName: autoroll-email-creds
- name: notifier-chat-config
secret:
secretName: notifier-chat-config