internal/rpmmd: change ignoressl to pointer
Change the `IgnoreSSL` field in `rpmmd.RepoConfig` to a pointer. This will be later used to configure the `SSLVerify` field in the yum repo stage.
This commit is contained in:
parent
173de3eba4
commit
ce299dfa0e
13 changed files with 89 additions and 82 deletions
|
|
@ -40,7 +40,7 @@ type RepoConfig struct {
|
|||
CheckGPG *bool `json:"check_gpg,omitempty"`
|
||||
CheckRepoGPG *bool `json:"check_repo_gpg,omitempty"`
|
||||
Priority *int `json:"priority,omitempty"`
|
||||
IgnoreSSL bool `json:"ignore_ssl,omitempty"`
|
||||
IgnoreSSL *bool `json:"ignore_ssl,omitempty"`
|
||||
MetadataExpire string `json:"metadata_expire,omitempty"`
|
||||
RHSM bool `json:"rhsm,omitempty"`
|
||||
Enabled *bool `json:"enabled,omitempty"`
|
||||
|
|
@ -67,7 +67,7 @@ func (r *RepoConfig) Hash() string {
|
|||
ats(r.GPGKeys)+
|
||||
bpts(r.CheckGPG)+
|
||||
bpts(r.CheckRepoGPG)+
|
||||
bts(r.IgnoreSSL)+
|
||||
bpts(r.IgnoreSSL)+
|
||||
r.MetadataExpire+
|
||||
bts(r.RHSM))))
|
||||
}
|
||||
|
|
|
|||
|
|
@ -222,7 +222,7 @@ func TestOldWorkerRepositoryCompatUnmarshal(t *testing.T) {
|
|||
GPGKeys: []string{"key1", "key2"},
|
||||
CheckGPG: common.ToPtr(true),
|
||||
CheckRepoGPG: common.ToPtr(true),
|
||||
IgnoreSSL: true,
|
||||
IgnoreSSL: common.ToPtr(true),
|
||||
Priority: common.ToPtr(10),
|
||||
MetadataExpire: "test",
|
||||
RHSM: true,
|
||||
|
|
@ -276,7 +276,7 @@ func TestOldWorkerRepositoryCompatMarshal(t *testing.T) {
|
|||
CheckGPG: common.ToPtr(true),
|
||||
CheckRepoGPG: common.ToPtr(true),
|
||||
Priority: common.ToPtr(10),
|
||||
IgnoreSSL: true,
|
||||
IgnoreSSL: common.ToPtr(true),
|
||||
MetadataExpire: "test",
|
||||
RHSM: true,
|
||||
Enabled: common.ToPtr(true),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue