blob: 12cef4983b618490b37d493c33e5634d82ff34e0 [file] [log] [blame]
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: autoroll-be-flutter-engine-flutter-autoroll
spec:
serviceName: "autoroll-be-flutter-engine-flutter-autoroll"
replicas: 1
selector:
matchLabels:
app: autoroll-be-flutter-engine-flutter-autoroll
updateStrategy:
type: RollingUpdate
template:
metadata:
labels:
app: autoroll-be-flutter-engine-flutter-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-flutter-engine-flutter-autoroll
image: gcr.io/skia-public/autoroll-be:2019-10-01T16_39_30Z-borenet-ad41711-clean
args:
- "--logtostderr"
- "--config=eyJjaGlsZE5hbWUiOiJFbmdpbmUiLCJjb250YWN0cyI6WyJsaXl1cWlhbkBnb29nbGUuY29tIiwicm1pc3RyeUBnb29nbGUuY29tIl0sImlzSW50ZXJuYWwiOmZhbHNlLCJwYXJlbnROYW1lIjoiRmx1dHRlciIsInBhcmVudFdhdGVyZmFsbCI6Imh0dHBzOi8vYnVpbGQuY2hyb21pdW0ub3JnL3AvY2xpZW50LmZsdXR0ZXIvY29uc29sZSIsInJvbGxlck5hbWUiOiJmbHV0dGVyLWVuZ2luZS1mbHV0dGVyLWF1dG9yb2xsIiwic2VydmljZUFjY291bnQiOiJmbHV0dGVyLWF1dG9yb2xsQHNraWEtcHVibGljLmlhbS5nc2VydmljZWFjY291bnQuY29tIiwic2hlcmlmZiI6WyJodHRwczovL3JvdGEtbmcuYXBwc3BvdC5jb20vbGVnYWN5L3NoZXJpZmZfZmx1dHRlcl9lbmdpbmUuanNvbiJdLCJzaGVyaWZmQmFja3VwIjpbImxpeXVxaWFuQGdvb2dsZS5jb20iXSwiZ2l0aHViIjp7InJlcG9Pd25lciI6ImZsdXR0ZXIiLCJyZXBvTmFtZSI6ImZsdXR0ZXIiLCJjaG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y2hzaWEvZnVjaHNpYS5zdGFtcCJdfSwia3ViZXJuZXRlcyI6eyJjcHUiOiIxIiwibWVtb3J5IjoiOEdpIiwiZGlzayI6IjUwR2kifSwibWF4Um9sbEZyZXF1ZW5jeSI6IjBtIiwibm90aWZpZXJzIjpbeyJmaWx0ZXIiOiJ3YXJuaW5nIiwiZW1haWwiOnsiZW1haWxzIjpbIiRTSEVSSUZGIl19fV19"
- "--email_creds=/var/secrets/autoroll-email-creds"
- "--firestore_instance=production"
- "--port=:8000"
- "--prom_port=:20000"
- "--recipes_cfg=/usr/local/share/autoroll/recipes.cfg"
- "--workdir=/data"
- "--chat_webhooks_file=/etc/notifier-chat-config/chat_config.txt"
ports:
- containerPort: 8000
- containerPort: 20000
volumeMounts:
- name: autoroll-be-flutter-engine-flutter-autoroll-storage
mountPath: /data
- name: autoroll-be-flutter-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/
- name: flutter-github-token
mountPath: /var/secrets/github-token
- name: flutter-ssh-key
mountPath: /var/secrets/ssh-key
env:
- name: GOOGLE_APPLICATION_CREDENTIALS
value: /var/secrets/google/key.json
- name: TMPDIR
value: /data/tmp
resources:
limits:
memory: "8Gi"
cpu: 1
readinessProbe:
httpGet:
path: /healthz
port: 8000
initialDelaySeconds: 600
periodSeconds: 60
failureThreshold: 10
volumes:
- name: autoroll-be-flutter-autoroll-sa
secret:
secretName: flutter-autoroll
- name: autoroll-email-creds
secret:
secretName: autoroll-email-creds
- name: notifier-chat-config
secret:
secretName: notifier-chat-config
- name: flutter-github-token
secret:
secretName: flutter-github-token
- name: flutter-ssh-key
secret:
secretName: flutter-ssh-key
volumeClaimTemplates:
- metadata:
name: autoroll-be-flutter-engine-flutter-autoroll-storage
spec:
accessModes: [ "ReadWriteOnce" ]
resources:
requests:
storage: 50Gi