weldr: accept rhsm parameter in sources
The system sources allow specification of the rhsm parameter, but it isn't available in the sources configured over the Weldr API. This patch implements support for it.
This commit is contained in:
parent
05ffdc70aa
commit
b950d6e062
5 changed files with 36 additions and 0 deletions
|
|
@ -187,6 +187,7 @@ func NewSourceConfigV1(id string, s store.SourceConfig) SourceConfigV1 {
|
|||
sc.CheckSSL = s.CheckSSL
|
||||
sc.System = s.System
|
||||
sc.Distros = s.Distros
|
||||
sc.RHSM = s.RHSM
|
||||
|
||||
return sc
|
||||
}
|
||||
|
|
@ -203,6 +204,7 @@ type SourceConfigV1 struct {
|
|||
Proxy string `json:"proxy,omitempty" toml:"proxy,omitempty"`
|
||||
GPGUrls []string `json:"gpgkey_urls,omitempty" toml:"gpgkey_urls,omitempty"`
|
||||
Distros []string `json:"distros,omitempty" toml:"distros,omitempty"`
|
||||
RHSM bool `json:"rhsm" toml:"rhsm"`
|
||||
}
|
||||
|
||||
// Key returns the key, .ID in this case
|
||||
|
|
@ -229,6 +231,7 @@ func (s SourceConfigV1) SourceConfig() (ssc store.SourceConfig) {
|
|||
ssc.CheckGPG = s.CheckGPG
|
||||
ssc.CheckSSL = s.CheckSSL
|
||||
ssc.Distros = s.Distros
|
||||
ssc.RHSM = s.RHSM
|
||||
|
||||
return ssc
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue