apiVersion: apps/v1
kind: Deployment
metadata:
  name: power-pod
  namespace: k3s-arm-demo
spec:
  selector:
    matchLabels:
      app: power-pod
  replicas: 1
  template:
    metadata:
      labels:
        app: power-pod
    spec:
      containers:
      - name: power-pod
        image: mak3r/pd:polling
        args: ["action.sh", "/usr/local/share/k3s/tc-enable", "6", "15"]
        securityContext:
          privileged: true
        volumeMounts:
          - mountPath: /dev/gpiomem
            name: power-out
          - mountPath: /usr/local/share/k3s
            name: k3s-arm-demo-share
      nodeSelector:
        nodetype: "master"
      restartPolicy: Always
      volumes:
      - name: power-out
        hostPath:
          path: /dev/gpiomem
      - name: k3s-arm-demo-share
        hostPath:
          path: /usr/local/share/k3s