blob: c9828f453a5d776b614fe472bb0e20d462fc4922 [file] [log] [blame]
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: autoroll-be-dart-sdk-flutter-engine
spec:
serviceName: "autoroll-be-dart-sdk-flutter-engine"
replicas: 1
selector:
matchLabels:
app: autoroll-be-dart-sdk-flutter-engine
updateStrategy:
type: RollingUpdate
template:
metadata:
labels:
app: autoroll-be-dart-sdk-flutter-engine # 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-dart-sdk-flutter-engine
image: gcr.io/skia-public/autoroll-be:2019-12-10T18_39_37Z-rmistry-214737f-clean
command: ["/usr/local/bin/autoroll-be"]
args:
- "--logtostderr"
- "--config=eyJjaGlsZE5hbWUiOiJEYXJ0IFNESyIsImNvbnRhY3RzIjpbInJtaXN0cnlAZ29vZ2xlLmNvbSIsImFhbUBnb29nbGUuY29tIl0sImlzSW50ZXJuYWwiOmZhbHNlLCJwYXJlbnROYW1lIjoiRmx1dHRlciBFbmdpbmUiLCJwYXJlbnRXYXRlcmZhbGwiOiJodHRwczovL2J1aWxkLmNocm9taXVtLm9yZy9wL2NsaWVudC5mbHV0dGVyL2NvbnNvbGUiLCJyb2xsZXJOYW1lIjoiZGFydC1zZGstZmx1dHRlci1lbmdpbmUiLCJzZXJ2aWNlQWNjb3VudCI6ImZsdXR0ZXItZW5naW5lLWF1dG9yb2xsQHNraWEtcHVibGljLmlhbS5nc2VydmljZWFjY291bnQuY29tIiwic2hlcmlmZiI6WyJkYXJ0LXZtLXRlYW1AZ29vZ2xlLmNvbSJdLCJnaXRodWIiOnsicmVwb093bmVyIjoiZmx1dHRlciIsInJlcG9OYW1lIjoiZW5naW5lIiwiY2hlY2tzTnVtIjoxMCwiY2hlY2tzV2FpdEZvciI6WyJsdWNpLWVuZ2luZSJdfSwiZnJlZVR5cGVSZXBvTWFuYWd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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-dart-sdk-flutter-engine-storage
mountPath: /data
- name: autoroll-be-flutter-engine-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-engine-github-token
mountPath: /var/secrets/github-token
- name: flutter-engine-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-engine-autoroll-sa
secret:
secretName: flutter-engine-autoroll
- name: autoroll-email-creds
secret:
secretName: autoroll-email-creds
- name: notifier-chat-config
secret:
secretName: notifier-chat-config
- name: flutter-engine-github-token
secret:
secretName: flutter-engine-github-token
- name: flutter-engine-ssh-key
secret:
secretName: flutter-engine-ssh-key
volumeClaimTemplates:
- metadata:
name: autoroll-be-dart-sdk-flutter-engine-storage
spec:
accessModes: [ "ReadWriteOnce" ]
resources:
requests:
storage: 50Gi