Michael Crosby
ae9af437f0
After parsing flags check that the command is nsenter
...
Signed-off-by: Michael Crosby <michael@docker.com>
2014-08-07 10:48:29 -07:00
Michael Crosby
5226b39d15
Fix issues in nsenter.c and console handling
...
Signed-off-by: Michael Crosby <michael@docker.com>
2014-08-06 22:04:28 -07:00
Michael Crosby
a48b001013
Refactor execin code to be simpler
...
Signed-off-by: Michael Crosby <michael@docker.com>
2014-08-06 18:44:41 -07:00
Michael Crosby
390f413a92
Make syncpipe transport generic data
...
Signed-off-by: Michael Crosby <michael@docker.com>
2014-08-06 18:00:52 -07:00
Michael Crosby
5589d4d879
Merge pull request #139 from milosgajdos83/tenus-libcontainer
...
RtAttr packaging fix. Added NetworkLinkDel() func and a new test.
2014-08-05 17:58:50 -07:00
Milos Gajdos
3ff181bb20
Replacing t.Fatal() with t.Fatalf()
...
Docker-DCO-1.1-Signed-off-by: Milos Gajdos <milosgajdos83@gmail.com> (github: milosgajdos83)
2014-08-06 01:29:37 +01:00
Milos Gajdos
e8abb5ca89
Replaced log.Fatalf() with t.Fatalf()
...
No need to import log package.
Docker-DCO-1.1-Signed-off-by: Milos Gajdos <milosgajdos83@gmail.com> (github: milosgajdos83)
2014-08-06 01:08:40 +01:00
Milos Gajdos
c5f4d90da5
Fixed rtnetlink attributes packaging into netlink message.
...
I've also added NetworkLinkDel() function which allows deleting
of the existing network links.
Docker-DCO-1.1-Signed-off-by: Milos Gajdos <milosgajdos83@gmail.com> (github: milosgajdos83)
2014-08-06 01:08:21 +01:00
Michael Crosby
f538117a7b
Merge pull request #144 from crosbymichael/move-c-code
...
Move nsenter C code to separate file
2014-08-05 16:13:35 -07:00
Michael Crosby
8b6c0b7ec6
Add linux style formatting
...
Signed-off-by: Michael Crosby <michael@docker.com>
2014-08-05 16:04:18 -07:00
Michael Crosby
f3b0a3a0e6
Move nsenter C code to separate file
...
Signed-off-by: Michael Crosby <michael@docker.com>
2014-08-05 16:04:08 -07:00
Michael Crosby
f79bccbcf0
Merge pull request #141 from vishh/runin_support
...
Change nsenter to support docker 'runin'
2014-08-05 15:18:39 -07:00
Vishnu Kannan
f90eee10ef
Remove debug message.
...
Docker-DCO-1.1-Signed-off-by: Vishnu Kannan <vishnuk@google.com> (github: vishh)
2014-08-05 22:13:23 +00:00
Vishnu Kannan
74b99b8dd6
Check for "nsenter" in args before parsing flags. Addressed comments.
...
Docker-DCO-1.1-Signed-off-by: Vishnu Kannan <vishnuk@google.com> (github: vishh)
2014-08-05 22:13:23 +00:00
Vishnu Kannan
e5e40b6ef0
Docker 'runin' demands passing flags before 'nsenter' cli option.
...
Docker does not require RunIn API. Hence that API has been removed.
nsinit CLI has been modified to work around the nsenter changes.
Docker-DCO-1.1-Signed-off-by: Vishnu Kannan <vishnuk@google.com> (github: vishh)
2014-08-05 22:13:23 +00:00
Michael Crosby
54cf66e07b
Merge pull request #140 from tianon/vendor
...
Add "update-vendor.sh" script and vendor our current deps...
2014-08-05 10:54:34 -07:00
Tianon Gravi
43cdc5934e
Run update-vendor.sh to vendor our deps
...
Signed-off-by: Andrew Page <admwiggin@gmail.com>
2014-08-04 17:24:17 -06:00
Tianon Gravi
e9f44b52de
Add "update-vendor.sh" script and vendor our current deps (minus Docker, since that'd make a circle)
...
Also, updated .travis.yml to use the new "vendor" directory (since this is pretty pointless without that :D)
Signed-off-by: Andrew Page <admwiggin@gmail.com>
2014-08-04 17:24:11 -06:00
Victor Marmol
68ea1234a0
Merge pull request #137 from mrunalp/dev/moveuplockthread
...
Lock the thread first thing in init.
2014-08-03 10:14:54 -07:00
Mrunal Patel
7f3bbbb47b
Move locking to caller.
...
Docker-DCO-1.1-Signed-off-by: Mrunal Patel <mrunalp@gmail.com> (github: mrunalp)
2014-08-01 19:06:56 -04:00
Victor Marmol
ef3c88435e
Merge pull request #136 from bernerdschaefer/nsinit-exec-with-flags
...
DefaultCreateCommand supports command w/ flags
2014-07-31 14:24:53 -07:00
Bernerd Schaefer
041fafc763
DefaultCreateCommand supports command w/ flags
...
namespaces.DefaultCreateCommand prepends the user-supplied command to
execute with "--", so that "nsinit init" does not attempt to interpret
it.
Docker-DCO-1.1-Signed-off-by: Bernerd Schaefer <bj.schaefer@gmail.com> (github: bernerdschaefer)
2014-07-31 21:32:10 +02:00
Rohit Jnagal
164cd807a1
Merge pull request #135 from peterbourgon/master
...
Only import "testing" from *_test.go
2014-07-30 09:33:29 -07:00
Peter Bourgon
c6edb4ad96
Only import "testing" from *_test.go
...
This prevents the testing package flags from leaking into the
flagsets of binaries that import libcontainer.
Docker-DCO-1.1-Signed-off-by: Peter Bourgon <peter@bourgon.org> (github: peterbourgon)
2014-07-30 18:15:12 +02:00
Rohit Jnagal
bc06326a5e
Merge pull request #134 from tianon/fix-more-dotclouds
...
Update more "dotcloud/docker" refs to "docker/docker"
2014-07-29 10:56:40 -07:00
Tianon Gravi
95ce3af4d0
Update more "dotcloud/docker" refs to "docker/docker"
...
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-07-29 11:21:55 -06:00
Victor Marmol
625c65804e
Merge pull request #103 from tianon/user
...
Move "pkg/user" into libcontainer...
2014-07-29 10:04:57 -07:00
Tianon Gravi
e31771fa42
Move "pkg/user" into libcontainer and add support for GetUserGroupSupplementary to return "Home" too
...
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-07-29 10:59:18 -06:00
Victor Marmol
7dc9dc3473
Merge pull request #58 from maebashi/fix-setns-order
...
fix the order of setns()
2014-07-29 09:45:13 -07:00
Victor Marmol
7cdbf095e0
Merge pull request #133 from soundcloud/non-linux-clock-ticks
...
Implement system.GetClockTicks for all platforms
2014-07-29 09:21:58 -07:00
Victor Marmol
5e2627e687
Merge pull request #130 from vishh/fix_cgroup_path
...
Make fs.GetStats() work when used from inside a docker container.
2014-07-29 09:21:46 -07:00
Bernerd Schaefer
eafabef56d
Implement system.GetClockTicks for all platforms
...
Docker-DCO-1.1-Signed-off-by: Bernerd Schaefer <bj.schaefer@gmail.com> (github: bernerdschaefer)
2014-07-29 14:37:47 +02:00
Vishnu Kannan
66aee74b1e
Libcontainer fs.GetStats() will not look for cgroups relative to the cgroup of init process if the parent
...
in cgroups.Cgroup is absolute. This is required to get stats of other containers while running inside a docker container.
Docker-DCO-1.1-Signed-off-by: Vishnu Kannan <vishnuk@google.com> (github: vishh)
2014-07-29 05:08:04 +00:00
Victor Marmol
e64f9a39c6
Merge pull request #105 from rhatdan/master
...
Add label.InitLabels functioni. Allows generation of labels based on options
2014-07-28 14:32:51 -07:00
Dan Walsh
bc3c671e21
Add label.InitLabels functioni. Allows generation of labels based on options
...
This will allow us to do the following with docker.
Customize the way that a labeling system like SELinux will run on a container.
--label-opt="user:USER" : Set the label user for the container
--label-opt="role:ROLE" : Set the label role for the container
--label-opt="type:TYPE" : Set the label type for the container
--label-opt="level:LEVEL" : Set the label level for the container
--label-opt="disabled" : Turn off label confinement for the container
Since we are passing a list of string options instead of a space separated
string of options, I will change function calls to use InitLabels instead of
GenLabels. Genlabels interface is Deprecated.
Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
2014-07-28 16:09:17 -04:00
maebashi
f333c5ce9b
remove unnecessary headers
...
Docker-DCO-1.1-Signed-off-by: Takahiro Maebashi <maebashi@iij.ad.jp> (github: maebashi)
2014-07-28 11:02:35 +09:00
Aleksa Sarai
01a7f19afe
namespaces: nsenter: ignore nonexistent namespaces
...
If a particular kernel doesn't have namespace directories that
libcontainer tries to attain during nsenter(), ignore the error (this is
consistent with the previous implementation of nsenter()).
Docker-DCO-1.1-Signed-off-by: Aleksa Sarai <cyphar@cyphar.com> (github: cyphar)
2014-07-28 11:02:17 +09:00
Victor Marmol
e6a43c1c2b
Merge pull request #128 from crosbymichael/fix-nsenter
...
Correct nsenter fprintf syntax
2014-07-24 15:09:25 -07:00
Victor Marmol
76f193085a
Merge pull request #127 from crosbymichael/update-docker-imports
...
Update imports for new docker location
2014-07-24 14:56:10 -07:00
Michael Crosby
52e7350c9d
Correct nsenter fprintf syntax
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@docker.com> (github: crosbymichael)
2014-07-24 14:54:05 -07:00
Michael Crosby
4568ca76c8
Update imports for new docker location
...
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@docker.com> (github: crosbymichael)
2014-07-24 14:28:49 -07:00
Michael Crosby
010e87b261
Merge pull request #123 from tianon/dockerfile-tweaks
...
Add a couple tweaks to the Dockerfile
2014-07-24 09:48:55 -07:00
Victor Marmol
f348ac401f
Merge pull request #121 from vishh/fix_network_stats
...
Fix veth network stats.
2014-07-24 09:13:39 -07:00
Victor Marmol
081a08e8a6
Merge pull request #126 from dhammika/125-null-term-ifr_name
...
Null-term ioctl ifr_name strings #125
2014-07-24 09:13:17 -07:00
Vishnu Kannan
47096e1ffd
Fix veth network stats. Tx on the host vETH is ingress traffic and not egress.
...
Docker-DCO-1.1-Signed-off-by: Vishnu Kannan <vishnuk@google.com> (github: vishh)
2014-07-24 05:50:44 +00:00
Dhammika Pathirana
c391368000
Null-term ioctl ifr_name strings
...
Docker-DCO-1.1-Signed-off-by: Dhammika Pathirana <dhammika@gmail.com> (github: dhammika)
2014-07-23 22:26:58 -07:00
Tianon Gravi
356f7a9136
Add a couple tweaks to the Dockerfile
...
- we don't need to add a "daemon" user to busybox; it already has one :)
- if we split out the "go get" from the "go install", we can have nice clean output on "docker build" of which dependencies we're pulling in and all the packages that get built :)
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-07-23 19:07:07 -06:00
Victor Marmol
6777537b30
Merge pull request #122 from tianon/makefile-rm
...
Add missing "--rm" on "make sh"
2014-07-23 18:03:12 -07:00
Tianon Gravi
f8e987f731
Add missing "--rm" on "make sh"
...
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-07-23 18:58:16 -06:00
Victor Marmol
052947809d
Merge pull request #120 from crosbymichael/add-tests1
...
Add busybox rootfs so we can run containers
2014-07-23 17:31:51 -07:00