apiVersion: apps/v1
kind: Deployment
metadata:
  name: cli
spec:
  replicas: 1
  revisionHistoryLimit: 2
  selector:
    matchLabels:
      app: cli
  template:
    metadata:
      labels:
        app: cli
    spec:
      containers:
        - name: cli
          image: target/consensource-cli
          imagePullPolicy: IfNotPresent
          resources:
            limits:
              cpu: 50m
              memory: 100Mi
            requests:
              cpu: 20m
              memory: 50Mi
          command:
            - bash
          args:
            - -c
            - |
              tail -f /dev/null
          volumeMounts:
            - name: consensource-keys
              mountPath: "/root/.sawtooth"
              readOnly: true
      volumes:
        - name: consensource-keys
          secret:
            secretName: cli
            items:
              - key: sawtooth-pub-key
                path: keys/root.pub
              - key: sawtooth-priv-key
                path: keys/root.priv