Commit graph

23 commits

Author SHA1 Message Date
William Thurston
755e5047a7 Fixes #5749
libcontainer support for arbitrary route table entries

Docker-DCO-1.1-Signed-off-by: William Thurston <me@williamthurston.com> (github: jhspaybar)
2014-05-28 17:42:02 +00:00
Alexander Larsson
db1a117450 Fix libcontainer network support on rhel6
It seems that netlink in older kernels, including RHEL6, does not
support RTM_SETLINK with IFLA_MASTER. It just silently ignores it, reporting
no error, causing netlink.NetworkSetMaster() to not do anything yet
return no error.

We fix this by introducing and using AddToBridge() in a very similar manner
to CreateBridge(), which use the old ioctls directly.

This fixes https://github.com/dotcloud/docker/issues/4668

Docker-DCO-1.1-Signed-off-by: Alexander Larsson <alexl@redhat.com> (github: alexlarsson)
2014-04-09 15:44:18 +02:00
Michael Crosby
ba89d04fbc Set bridge mac addr on supported kernels
Fixes #3200
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-03-31 22:56:23 +00:00
Guillaume J. Charmes
a890f18e9a Simplify code + Allow more generic attr children + remove prefix
Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume.charmes@docker.com> (github: creack)
2014-02-12 09:29:06 -08:00
Guillaume J. Charmes
19445d3dfc Merge remote-tracking branch 'mike/add-netlink-functions' into implement_create_veth
Conflicts:
	pkg/netlink/netlink_linux.go

Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume.charmes@docker.com> (github: creack)
2014-02-12 04:17:12 -08:00
Guillaume J. Charmes
000df04348 Implement create veth
Docker-DCO-1.1-Signed-off-by: Guillaume J. Charmes <guillaume.charmes@docker.com> (github: creack)
2014-02-12 04:09:56 -08:00
Michael Crosby
43a219048a Merge branch 'add-netlink-functions' of github.com:crosbymichael/docker into add-netlink-functions
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-11 03:33:18 -08:00
Tianon Gravi
6675d69513 Add comment clarifying null termination
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-02-11 10:32:31 -07:00
Michael Crosby
f697f1d648 Exec out to ip right now for creating the veth pair
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-11 03:32:35 -08:00
Michael Crosby
1d3028efa3 Add more netlink functions for set ns by fd and bring iface down
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-10 22:32:07 -08:00
Michael Crosby
a37785b64f Allow add of empty name
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-10 16:41:16 -08:00
Michael Crosby
f62dcac1c5 Create veth pair via netlink
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-10 13:37:16 -08:00
Michael Crosby
4b4a12a4c3 Improve get if socket loop
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-10 11:36:23 -08:00
Tianon Gravi
e44920cbe6 Update NetworkChangeName to be more similar to my original (moving IFNAMSIZ constant outside the function like it should've been)
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-02-09 18:14:17 -07:00
Michael Crosby
4f9817a3ca Replace my C code with tianons Go code
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-09 05:54:13 -08:00
Michael Crosby
971834148c Use c to change interface name
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-08 20:44:04 -08:00
Michael Crosby
708c7be9d2 Add network set interface in namespace by pid
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-08 10:03:16 -08:00
Michael Crosby
a5bf8abb77 Add set master for interface
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
2014-02-08 09:53:04 -08:00
Tianon Gravi
0af651da27 Update/fix build tags, Dockerfile, and release.sh for proper building and releasing of linux/386 and linux/arm cross-compiled client binaries
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-01-31 03:16:42 -07:00
Johan Euphrosine
abbdc2b6ce netlink: move Route type to common arch file
Docker-DCO-1.1-Signed-off-by: Johan Euphrosine <proppy@google.com> (github: proppy)
2014-01-17 14:04:11 -08:00
Johan Euphrosine
612d2298ab netlink: add default Route to NetworkGetRoutes
Docker-DCO-1.1-Signed-off-by: Johan Euphrosine <proppy@google.com> (github: proppy)
2014-01-17 11:09:50 -08:00
Tianon Gravi
b8f8d57300 Fix a few miscellaneous typos (Unkown -> Unknown, Recieve -> Receive)
Docker-DCO-1.0-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-01-07 22:15:53 -07:00
Solomon Hykes
38e2bb05e9 Move utility package 'netlink' to pkg/netlink 2013-12-23 23:39:39 +00:00