apiVersion: apps/v1
kind: DaemonSet
metadata:
  namespace: trusted-identity
  name: vtpm2-server
spec:
  selector:
    matchLabels:
      name: vtpm2-server
  template:
    metadata:
      labels:
        name: vtpm2-server
    spec:
      containers:
        - name: vtpm2-server-pub
          #image: {{ .Values.tiRepo }}/{{ index .Values "ti-key-release-1" "jssService" "type" }}:{{ .Chart.AppVersion  }}
          image: trustedseriviceidentity/vtpm2-server:v1.5
          imagePullPolicy: Always
          env:
            - name: ISS
              value: "wsched@us.ibm.com"
            - name: TTL_SEC
              value: "30"
          ports:
          - name: http
            containerPort: 5000
            protocol: TCP
            hostPort: 5000
          volumeMounts:
          - mountPath: /host/sockets
            name: tsi-sockets
      volumes:
      - name: tsi-sockets
        hostPath:
          # directory location on host
           path: /tsi-secure/sockets
           # directory might be created
           type: DirectoryOrCreate
