Moved the TOML based Configuration to dnet

The configuration format for docker runtime is based on daemon flags and
hence adjusting the libnetwork configuration to accomodate it by moving
the TOML based configuration to the dnet tool.

Also changed the controller configuration via options

Signed-off-by: Madhu Venugopal <madhu@docker.com>
This commit is contained in:
Madhu Venugopal
2015-06-12 12:46:12 -07:00
parent acfac0ba4c
commit f8eb4da90c
12 changed files with 142 additions and 58 deletions
+10 -10
View File
@@ -79,7 +79,7 @@ func i2cL(i interface{}) []*containerResource {
}
func createTestNetwork(t *testing.T, network string) (libnetwork.NetworkController, libnetwork.Network) {
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}
@@ -174,7 +174,7 @@ func TestJson(t *testing.T) {
func TestCreateDeleteNetwork(t *testing.T) {
defer netutils.SetupTestNetNS(t)()
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}
@@ -252,7 +252,7 @@ func TestCreateDeleteNetwork(t *testing.T) {
func TestGetNetworksAndEndpoints(t *testing.T) {
defer netutils.SetupTestNetNS(t)()
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}
@@ -525,7 +525,7 @@ func TestGetNetworksAndEndpoints(t *testing.T) {
func TestProcGetServices(t *testing.T) {
defer netutils.SetupTestNetNS(t)()
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}
@@ -1001,7 +1001,7 @@ func TestAttachDetachBackend(t *testing.T) {
}
func TestDetectGetNetworksInvalidQueryComposition(t *testing.T) {
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}
@@ -1108,7 +1108,7 @@ func TestFindNetworkUtil(t *testing.T) {
func TestCreateDeleteEndpoints(t *testing.T) {
defer netutils.SetupTestNetNS(t)()
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}
@@ -1234,7 +1234,7 @@ func TestCreateDeleteEndpoints(t *testing.T) {
func TestJoinLeave(t *testing.T) {
defer netutils.SetupTestNetNS(t)()
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}
@@ -1674,7 +1674,7 @@ func TestwriteJSON(t *testing.T) {
func TestHttpHandlerUninit(t *testing.T) {
defer netutils.SetupTestNetNS(t)()
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}
@@ -1740,7 +1740,7 @@ func TestHttpHandlerBadBody(t *testing.T) {
rsp := newWriter()
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}
@@ -1772,7 +1772,7 @@ func TestEndToEnd(t *testing.T) {
rsp := newWriter()
c, err := libnetwork.New("")
c, err := libnetwork.New()
if err != nil {
t.Fatal(err)
}