mirror of
https://github.com/containers/podman.git
synced 2025-12-13 02:09:16 +08:00
Vendor c/common changes
Vendor latest c/common with changes to add a new Farms table to containers.conf and update system connection to add a connection to a farm when --farm is set. Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
This commit is contained in:
14
vendor/github.com/containers/common/pkg/config/config.go
generated
vendored
14
vendor/github.com/containers/common/pkg/config/config.go
generated
vendored
@@ -79,6 +79,8 @@ type Config struct {
|
||||
Secrets SecretConfig `toml:"secrets"`
|
||||
// ConfigMap section defines configurations for the configmaps management
|
||||
ConfigMaps ConfigMapConfig `toml:"configmaps"`
|
||||
// Farms defines configurations for the buildfarm farms
|
||||
Farms FarmConfig `toml:"farms"`
|
||||
}
|
||||
|
||||
// ContainersConfig represents the "containers" TOML config table
|
||||
@@ -676,6 +678,14 @@ type MachineConfig struct {
|
||||
Provider string `toml:"provider,omitempty"`
|
||||
}
|
||||
|
||||
// FarmConfig represents the "farm" TOML config tabls
|
||||
type FarmConfig struct {
|
||||
// Default is the default farm to be used when farming out builds
|
||||
Default string `toml:"default,omitempty"`
|
||||
// List is a map of farms created where key=farm-name and value=list of connections
|
||||
List map[string][]string `toml:"list,omitempty"`
|
||||
}
|
||||
|
||||
// Destination represents destination for remote service
|
||||
type Destination struct {
|
||||
// URI, required. Example: ssh://root@example.com:22/run/podman/podman.sock
|
||||
@@ -1241,6 +1251,10 @@ func ReadCustomConfig() (*Config, error) {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
// Let's always initialize the farm list so it is never nil
|
||||
if newConfig.Farms.List == nil {
|
||||
newConfig.Farms.List = make(map[string][]string)
|
||||
}
|
||||
return newConfig, nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user