apiVersion: apps/v1
kind: Deployment
metadata:
  name: ws
  labels:
    control-plane: login
spec:
  selector:
    matchLabels:
      control-plane: login
  replicas: 1
  template:
    metadata:
      labels:
        control-plane: login
      annotations:
        kubectl.kubernetes.io/default-logs-container: ws
    spec:
      securityContext:
        runAsNonRoot: true
      containers:
      - command:
        - /manager
        args:
        - --leader-elect
        - --issuer=https://login.do.storageos.net/dex
        - --redirect-uri=https://login.do.storageos.net/callback
        image: croomes/hive-login:develop
        imagePullPolicy: Always
        name: ws
        ports:
        - containerPort: 9443
          name: web-server
          protocol: TCP
        securityContext:
          allowPrivilegeEscalation: false
        livenessProbe:
          httpGet:
            path: /healthz
            port: 8081
          initialDelaySeconds: 15
          periodSeconds: 20
        readinessProbe:
          httpGet:
            path: /readyz
            port: 8081
          initialDelaySeconds: 5
          periodSeconds: 10
        resources:
          limits:
            cpu: 100m
            memory: 30Mi
          requests:
            cpu: 100m
            memory: 20Mi
      serviceAccountName: sa
      terminationGracePeriodSeconds: 10
