mirror of
https://github.com/moby/moby.git
synced 2026-01-11 18:51:37 +00:00
Merge pull request #50601 from thaJeztah/cleanup_buildSandboxOptions
daemon: make buildSandboxOptions, buildSandboxPlatformOptions more atomic
This commit is contained in:
@@ -61,10 +61,13 @@ func buildSandboxOptions(cfg *config.Config, ctr *container.Container) ([]libnet
|
||||
sboxOptions = append(sboxOptions, libnetwork.OptionUseExternalKey())
|
||||
}
|
||||
|
||||
// Add platform-specific Sandbox options.
|
||||
if err := buildSandboxPlatformOptions(ctr, cfg, &sboxOptions); err != nil {
|
||||
// Update the container with platform-specific options, and
|
||||
// add platform-specific Sandbox options.
|
||||
platformOpts, err := buildSandboxPlatformOptions(ctr, cfg)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
sboxOptions = append(sboxOptions, platformOpts...)
|
||||
|
||||
if len(ctr.HostConfig.DNS) > 0 {
|
||||
dnsAddrs, err := toNetIP(ctr.HostConfig.DNS)
|
||||
|
||||
Reference in New Issue
Block a user