File tree Expand file tree Collapse file tree
crates/stackable-operator/src/crd/git_sync Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -35,6 +35,7 @@ pub const GIT_SYNC_LINK: &str = "current";
3535pub const CA_CERT_VOLUME_NAME_PREFIX : & str = "ca-cert" ;
3636pub const CA_CERT_MOUNT_PATH_PREFIX : & str = "/stackable/gitca" ;
3737pub const GIT_SSL_CA_INFO_CONFIG_KEY : & str = "http.sslCAInfo" ;
38+ pub const GIT_SSL_VERIFY : & str = "http.sslverify" ;
3839
3940#[ derive( Snafu , Debug , EnumDiscriminants ) ]
4041#[ strum_discriminants( derive( IntoStaticStr ) ) ]
@@ -327,6 +328,12 @@ impl GitSyncResources {
327328 internal_git_config. insert ( GIT_SSL_CA_INFO_CONFIG_KEY . to_owned ( ) , path. to_owned ( ) ) ;
328329 }
329330
331+ // Tls defaults to webPki but if the user has *explicitly* set this to
332+ // null then we honour this by deactivating the ssl check.
333+ if git_sync. tls . tls . is_none ( ) {
334+ internal_git_config. insert ( GIT_SSL_VERIFY . to_owned ( ) , "false" . to_owned ( ) ) ;
335+ }
336+
330337 let mut git_sync_config = git_sync. git_sync_conf . clone ( ) ;
331338
332339 // The key and value in Git configs are separated by a colon, but both can contain either
You can’t perform that action at this time.
0 commit comments