docker/config: update -mtu flag default
Docker-DCO-1.1-Signed-off-by: Johan Euphrosine <proppy@google.com> (github: google)
This commit is contained in:
parent
1b9c5edc6c
commit
92e61f89aa
3 changed files with 7 additions and 6 deletions
|
@ -49,7 +49,7 @@ func DaemonConfigFromJob(job *engine.Job) *DaemonConfig {
|
|||
if mtu := job.GetenvInt("Mtu"); mtu != 0 {
|
||||
config.Mtu = mtu
|
||||
} else {
|
||||
config.Mtu = DefaultNetworkMtu
|
||||
config.Mtu = GetDefaultNetworkMtu()
|
||||
}
|
||||
config.DisableNetwork = job.Getenv("BridgeIface") == DisableNetworkBridge
|
||||
|
||||
|
|
|
@ -43,7 +43,7 @@ func main() {
|
|||
flInterContainerComm = flag.Bool([]string{"#icc", "-icc"}, true, "Enable inter-container communication")
|
||||
flGraphDriver = flag.String([]string{"s", "-storage-driver"}, "", "Force the docker runtime to use a specific storage driver")
|
||||
flHosts = docker.NewListOpts(docker.ValidateHost)
|
||||
flMtu = flag.Int([]string{"#mtu", "-mtu"}, docker.GetDefaultNetworkMtu(), "Set the containers network mtu")
|
||||
flMtu = flag.Int([]string{"#mtu", "-mtu"}, 0, "Set the containers network MTU; if no value is provided: default to the default route MTU or 1500 if not default route is available")
|
||||
)
|
||||
flag.Var(&flDns, []string{"#dns", "-dns"}, "Force docker to use specific DNS servers")
|
||||
flag.Var(&flHosts, []string{"H", "-host"}, "tcp://host:port, unix://path/to/socket, fd://* or fd://socketfd to use in daemon mode. Multiple sockets can be specified")
|
||||
|
|
|
@ -4,9 +4,6 @@ import (
|
|||
"archive/tar"
|
||||
"bytes"
|
||||
"fmt"
|
||||
"github.com/dotcloud/docker"
|
||||
"github.com/dotcloud/docker/engine"
|
||||
"github.com/dotcloud/docker/utils"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
|
@ -16,6 +13,10 @@ import (
|
|||
"strings"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/dotcloud/docker"
|
||||
"github.com/dotcloud/docker/engine"
|
||||
"github.com/dotcloud/docker/utils"
|
||||
)
|
||||
|
||||
// This file contains utility functions for docker's unit test suite.
|
||||
|
@ -32,7 +33,7 @@ func mkRuntime(f utils.Fataler) *docker.Runtime {
|
|||
config := &docker.DaemonConfig{
|
||||
Root: root,
|
||||
AutoRestart: false,
|
||||
Mtu: docker.DefaultNetworkMtu,
|
||||
Mtu: docker.GetDefaultNetworkMtu(),
|
||||
}
|
||||
|
||||
eng, err := engine.New(root)
|
||||
|
|
Loading…
Reference in a new issue