apiVersion: apps/v1
kind: Deployment
metadata:
  annotations:
    kompose.cmd: kompose convert
    kompose.version: 1.22.0 (955b78124)
  labels:
    io.kompose.service: rabbitmq
  name: rabbitmq
spec:
  replicas: 1
  selector:
    matchLabels:
      io.kompose.service: rabbitmq
  strategy:
    type: Recreate
  template:
    metadata:
      annotations:
        kompose.cmd: kompose convert
        kompose.version: 1.22.0 (955b78124)
      labels:
        io.kompose.service: rabbitmq
    spec:
      containers:
        - env:
            - name: RABBITMQ_DEFAULT_USER
              value: "guest"
            - name: RABBITMQ_DEFAULT_PASS
              value: "guest"
          image: rabbitmq:3.8.14-management
          name: rabbitmq
          # command: [ "/bin/bash", "-ce", "tail -f /dev/null" ] #避免启动后退出
          ports:
            - containerPort: 5672
            - containerPort: 15672
          resources: {}
          volumeMounts:
            - mountPath: /var/lib/rabbitmq
              name: rabbitmq-claim0
            - mountPath: /var/log/rabbitmq
              name: rabbitmq-claim1
      restartPolicy: Always
      volumes:
        - name: rabbitmq-claim0
          persistentVolumeClaim:
            claimName: rabbitmq-claim0
        - name: rabbitmq-claim1
          persistentVolumeClaim:
            claimName: rabbitmq-claim1
