---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: galaxy
  labels:
    app: galaxy
spec:
  replicas: 1
  selector:
    matchLabels:
      app: galaxy
  template:
    metadata:
      labels:
        app: galaxy
    spec:
      containers:
        - name: galaxy
          image: pulp/pulp-galaxy-ng:latest
          ports:
            - containerPort: 80
              protocol: TCP
          volumeMounts:
            - name: galaxy-volume
              mountPath: /etc/pulp
              subPath: settings
            - name: galaxy-volume
              mountPath: /var/lib/pulp
              subPath: pulpstorage
            - name: galaxy-volume
              mountPath: /var/lib/pgsql
              subPath: pgsql
            - name: galaxy-volume
              mountPath: /var/lib/containers
              subPath: containers
            - name: galaxy-config
              mountPath: /etc/pulp/settings.py
              subPath: settings.py
      volumes:
        - name: galaxy-volume
          persistentVolumeClaim:
            claimName: galaxy-claim
        - name: galaxy-config
          configMap:
            name: galaxy-configmap
