apiVersion: apps/v1
kind: Deployment
metadata:
  name: boinc
  labels:
    app: boinc
spec:
  replicas: 1
  selector:
    matchLabels:
      app: boinc
  template:
    metadata:
      labels:
        app: boinc
    spec:
      volumes:
        - name: boinc-workspace
          emptyDir: {}
      containers:
        - name: boinc-client
          # this is the updated arm32v7 version of the image, for other platforms use the official boinc/client:latest
          image: tmcsantos/boinc-client:latest
          command: ["/usr/bin/boinc"]
          args: ["--no_gpus"]
          imagePullPolicy: Always
          lifecycle:
            preStop:
              exec:
                command: ["/usr/bin/boinccmd", "--quit"]
          envFrom:
            - secretRef:
                name: boinc-account
          volumeMounts:
            - name: boinc-workspace
              mountPath: /var/lib/boinc
