mirror of
https://github.com/vmware-tanzu/velero.git
synced 2026-01-05 13:05:17 +00:00
Support setting a custom CA bundle to use with a BackupStorageLocation (#2353)
* Support setting a custom CA certificate for a BSL Signed-off-by: Sam Lucidi <slucidi@redhat.com> * update CRDS Signed-off-by: Sam Lucidi <slucidi@redhat.com> * Add changelog for #2353 Signed-off-by: Sam Lucidi <slucidi@redhat.com> * Clean up temp file from TestTempCACertFile Signed-off-by: Sam Lucidi <slucidi@redhat.com>
This commit is contained in:
@@ -47,11 +47,12 @@ type backupStatusLine struct {
|
||||
// GetSnapshotID runs a 'restic snapshots' command to get the ID of the snapshot
|
||||
// in the specified repo matching the set of provided tags, or an error if a
|
||||
// unique snapshot cannot be identified.
|
||||
func GetSnapshotID(repoIdentifier, passwordFile string, tags map[string]string, env []string) (string, error) {
|
||||
func GetSnapshotID(repoIdentifier, passwordFile string, tags map[string]string, env []string, caCertFile string) (string, error) {
|
||||
cmd := GetSnapshotCommand(repoIdentifier, passwordFile, tags)
|
||||
if len(env) > 0 {
|
||||
cmd.Env = env
|
||||
}
|
||||
cmd.CACertFile = caCertFile
|
||||
|
||||
stdout, stderr, err := exec.RunCommand(cmd.Cmd())
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user