From 06601f245839125c508930e2b60e10593391aba8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=89=E5=BC=A0=E7=BA=B8?= Date: Fri, 6 Mar 2015 12:52:10 +0800 Subject: [PATCH] Update README.md add Process.wait to example script, fix the zombie process problem --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 9c85a18..e66b003 100644 --- a/README.md +++ b/README.md @@ -31,9 +31,10 @@ c = LXC::Container.new('foo') c.create('ubuntu') # create a container named foo with ubuntu template c.start # attach to a running container -c.attach do +pid = c.attach do LXC.run_command('ifconfig eth0') end +Process.wait(pid) c.stop c.destroy ```