apiVersion: v1
kind: ReplicationController
metadata:
  name: registry
spec:
  replicas: 1
  selector:
    name: registry
  template:
    metadata:
      labels:
        name: registry
    spec:
      containers:
        - name: registry
          image: registry:2
          env:
            - name: REGISTRY_STORAGE_DELETE_ENABLED
              value: "true"
            - name: REGISTRY_LOG_LEVEL
              value: info
            - name: REGISTRY_STORAGE
              value: filesystem
          ports:
            - containerPort: 5000
          volumeMounts:
            - name: registry-storage
              mountPath: /var/lib/registry
            - name: registry-creds
              mountPath: /var/run/secrets/deis/registry/creds
      volumes:
        - name: registry-storage
          emptyDir: {}
        - name: registry-creds
          secret:
            secretName: fs-keyfile
