apiVersion: apps/v1
kind: Deployment
metadata:
  name: go-file-reader
  namespace: default
  labels:
    app: go-file-reader
spec:
  replicas: 1
  selector:
    matchLabels:
      app: go-file-reader
  template:
    metadata:
      labels:
        app: go-file-reader
    spec:
      containers:
        - name: go-file-reader
          image: bygui86/go-file-reader:v1.0.0
          imagePullPolicy: IfNotPresent
          env:
            - name: FILE_PATH
              value: "/bin/data/source.txt"
          resources:
            requests:
              cpu: 100m
              memory: 64Mi
            limits:
              cpu: 100m
              memory: 64Mi
          volumeMounts:
            - name: data
              mountPath: /bin/data/
      volumes:
        - name: data
          persistentVolumeClaim:
            claimName: data-go-file-reader
