---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: jenkins 
  namespace: jenkins 
spec:
  replicas: 1
  selector:
    matchLabels:
      app: jenkins 
  template:
    metadata:
      labels:
        app: jenkins 
    spec:
      containers:
        - name: jenkins 
          image: jenkins/jenkins:lts-jdk11 
          ports:
          - containerPort: 8080
          volumeMounts:
            - name: jenkins-persistent-storage
              mountPath: /var/jenkins_home
      volumes:
        - name: jenkins-persistent-storage
          persistentVolumeClaim:
            claimName: pv002

