diff --git a/pkg/controller/jenkins/configuration/base/resources/pod.go b/pkg/controller/jenkins/configuration/base/resources/pod.go index 57ef94f0..9937ee02 100644 --- a/pkg/controller/jenkins/configuration/base/resources/pod.go +++ b/pkg/controller/jenkins/configuration/base/resources/pod.go @@ -33,6 +33,9 @@ const ( // this scripts are provided by user JenkinsUserConfigurationVolumePath = "/var/jenkins/user-configuration" + jenkinsBackupCredentialsVolumeName = "backup-credentials" + jenkinsBackupCredentialsVolumePath = "/var/jenkins/backup-credentials" + httpPortName = "http" slavePortName = "slavelistener" // HTTPPortInt defines Jenkins master HTTP port @@ -152,6 +155,11 @@ func NewJenkinsMasterPod(objectMeta metav1.ObjectMeta, jenkins *virtuslabv1alpha MountPath: jenkinsOperatorCredentialsVolumePath, ReadOnly: true, }, + { + Name: jenkinsBackupCredentialsVolumeName, + MountPath: jenkinsBackupCredentialsVolumePath, + ReadOnly: true, + }, }, }, }, @@ -210,6 +218,14 @@ func NewJenkinsMasterPod(objectMeta metav1.ObjectMeta, jenkins *virtuslabv1alpha }, }, }, + { + Name: jenkinsBackupCredentialsVolumeName, + VolumeSource: corev1.VolumeSource{ + Secret: &corev1.SecretVolumeSource{ + SecretName: GetBackupCredentialsSecretName(jenkins), + }, + }, + }, }, }, }