apiVersion: apps/v1
kind: StatefulSet
metadata:
  name: sample
spec:
  replicas: 3
  selector:
    matchLabels:
      app: sample
  serviceName: sample
  template:
    metadata:
      labels:
        app: sample
    spec:
      containers:
        - command:
            - sleep
            - inf
          image: alpine:3.14.2
          name: alpine
          volumeMounts:
            - mountPath: /sample
              name: vol
  volumeClaimTemplates:
    - metadata:
        name: vol
      spec:
        accessModes:
          - ReadWriteOnce
        resources:
          requests:
            storage: 100Mi
