Signed-off-by: John Howard <jhoward@microsoft.com>
| ... | ... |
@@ -39,6 +39,13 @@ type LogConfig struct {
|
| 39 | 39 |
Config map[string]string `json:"log-opts,omitempty"` |
| 40 | 40 |
} |
| 41 | 41 |
|
| 42 |
+// commonBridgeConfig stores all the platform-common bridge driver specific |
|
| 43 |
+// configuration. |
|
| 44 |
+type commonBridgeConfig struct {
|
|
| 45 |
+ Iface string `json:"bridge,omitempty"` |
|
| 46 |
+ FixedCIDR string `json:"fixed-cidr,omitempty"` |
|
| 47 |
+} |
|
| 48 |
+ |
|
| 42 | 49 |
// CommonTLSOptions defines TLS configuration for the daemon server. |
| 43 | 50 |
// It includes json tags to deserialize configuration from a file |
| 44 | 51 |
// using the same names that the flags in the command line uses. |
| ... | ... |
@@ -38,15 +38,16 @@ type Config struct {
|
| 38 | 38 |
// bridgeConfig stores all the bridge driver specific |
| 39 | 39 |
// configuration. |
| 40 | 40 |
type bridgeConfig struct {
|
| 41 |
+ commonBridgeConfig |
|
| 42 |
+ |
|
| 43 |
+ // Fields below here are platform specific. |
|
| 41 | 44 |
EnableIPv6 bool `json:"ipv6,omitempty"` |
| 42 | 45 |
EnableIPTables bool `json:"iptables,omitempty"` |
| 43 | 46 |
EnableIPForward bool `json:"ip-forward,omitempty"` |
| 44 | 47 |
EnableIPMasq bool `json:"ip-mask,omitempty"` |
| 45 | 48 |
EnableUserlandProxy bool `json:"userland-proxy,omitempty"` |
| 46 | 49 |
DefaultIP net.IP `json:"ip,omitempty"` |
| 47 |
- Iface string `json:"bridge,omitempty"` |
|
| 48 | 50 |
IP string `json:"bip,omitempty"` |
| 49 |
- FixedCIDR string `json:"fixed-cidr,omitempty"` |
|
| 50 | 51 |
FixedCIDRv6 string `json:"fixed-cidr-v6,omitempty"` |
| 51 | 52 |
DefaultGatewayIPv4 net.IP `json:"default-gateway,omitempty"` |
| 52 | 53 |
DefaultGatewayIPv6 net.IP `json:"default-gateway-v6,omitempty"` |
| ... | ... |
@@ -14,9 +14,7 @@ var ( |
| 14 | 14 |
// bridgeConfig stores all the bridge driver specific |
| 15 | 15 |
// configuration. |
| 16 | 16 |
type bridgeConfig struct {
|
| 17 |
- FixedCIDR string |
|
| 18 |
- NetworkMode string |
|
| 19 |
- Iface string `json:"bridge,omitempty"` |
|
| 17 |
+ commonBridgeConfig |
|
| 20 | 18 |
} |
| 21 | 19 |
|
| 22 | 20 |
// Config defines the configuration of a docker daemon. |