apiVersion: v1
kind: Pod
metadata:
  name: shm-demo
spec:
  containers:
  - name: server
    image: cheneyyu/shm-demo
    resources:
      limits:
        cpu: "1"
        memory: "1G"
    volumeMounts:
    - name: cache-volume
      mountPath: /dev/shm

  - name: function-1
    image: cheneyyu/shm-demo
    resources:
      limits:
        cpu: "1"
        memory: "1G"
    volumeMounts:
    - name: cache-volume
      mountPath: /dev/shm
  volumes:
  - emptyDir:
      medium: Memory
      sizeLimit: 1024Mi
    name: cache-volume