Store the container in the handler, so it is accessible
everywhere.
Signed-off-by: Daniel Lezcano
---
src/lxc/start.c | 12 +++-
src/lxc/start.h |1 +
2 files changed, 12 insertions(+), 1 deletion(-)
Index: lxc/src/lxc/start.c
==
When the reboot is detected, reboot the container.
Signed-off-by: Daniel Lezcano
---
src/lxc/commands.c |7 +++
src/lxc/conf.c |6 --
src/lxc/conf.h |1 +
src/lxc/confile.c | 30 +++---
src/lxc/lxc.h |3 ++-
src/lxc/lxc_start.c
This patch allows to shutdown the container when the system
is powered off in the container.
Signed-off-by: Daniel Lezcano
---
src/lxc/Makefile.am |6 +-
src/lxc/start.c | 11 +++
src/lxc/utmp.c | 156
src/lxc/utmp.h | 2
Use a prefixed enum to avoid conflict later.
Signed-off-by: Daniel Lezcano
---
src/lxc/conf.c| 14 +++---
src/lxc/conf.h| 12 ++--
src/lxc/confile.c | 10 +-
3 files changed, 18 insertions(+), 18 deletions(-)
Index: lxc/src/lxc/conf.c
==
The actual behaviour of the console is messy as:
* it relies on a heuristic (tty or not, rootfs or not, etc ...)
* the container init stole the tty and we lose the control
The following patch:
* allocates a tty
* maps this tty to the container console
* proxy the io from the console to the fi
This patch adds a function to count the number of tasks in the
container.
Signed-off-by: Daniel Lezcano
---
src/lxc/cgroup.c | 27 +++
src/lxc/cgroup.h |2 +-
2 files changed, 28 insertions(+), 1 deletion(-)
Index: lxc/src/lxc/cgroup.c
=
Factore out the console code and encapsulate the code in
functions.
Signed-off-by: Daniel Lezcano
---
src/lxc/lxc_console.c | 67 --
1 file changed, 43 insertions(+), 24 deletions(-)
Index: lxc/src/lxc/lxc_console.c
=
No need to include the lxc_conf structure definition, a forward
declaration is enough.
Signed-off-by: Daniel Lezcano
---
src/lxc/start.h |6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
Index: lxc/src/lxc/start.h
===
Use the mainloop to manage io of the console.
Signed-off-by: Daniel Lezcano
---
src/lxc/lxc_console.c | 163 ++
1 file changed, 88 insertions(+), 75 deletions(-)
Index: lxc/src/lxc/lxc_console.c
===
Add missing include
Signed-off-by: Daniel Lezcano
---
src/lxc/state.c |2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: lxc/src/lxc/state.c
===
--- lxc.orig/src/lxc/state.c
+++ lxc/src/lxc/state.c
@@ -26,7 +26,7 @@
#
* console improvements
* shutdown / poweroff / reboot support
--
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose
On Wed, Feb 3, 2010 at 7:34 PM, wrote:
> It seems that we did not the same kind of utils.
> You have made init.d, start, stop and status scripts (for debian-like
> distro).
> It could proposed to the debian package maintainer.
Sure, I'd be happy to have contributions to the debian package! :)
(b
12 matches
Mail list logo