]> git.proxmox.com Git - mirror_lxc.git/commitdiff
Add lxc.7 man page
authordlezcano <dlezcano>
Thu, 20 Nov 2008 15:04:09 +0000 (15:04 +0000)
committerdlezcano <dlezcano>
Thu, 20 Nov 2008 15:04:09 +0000 (15:04 +0000)
From: Daniel Lezcano <dlezcano@fr.ibm.com>

Added the overview man page for lxc.

Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
configure.in
doc/Makefile.am
src/lxc/start.c

index bcfc564024d4daab203664ac668e2c6b01fc1b9d..1b905c5020caa7862063ab20dcfe76e47c848260 100644 (file)
@@ -58,6 +58,7 @@ AC_CONFIG_FILES([
        doc/lxc-ps.sgml
        doc/lxc-cgroup.sgml
        doc/lxc.conf.sgml
+       doc/lxc.sgml
 
         src/Makefile
        src/lxc/Makefile
@@ -82,6 +83,7 @@ if test "x$DOCBOOK" = "xno"; then
 Warning:
 --------
 The docbook tool is not installed, the man pages won't be generated.
+If you want the man pages, install docbook and rerun 'configure'.
 
 ])
 
index 707aa9bce01fe28e627d79d9ddccb622b69f33b1..f4298fd7eb74bd9f70dd8c50f645bd3022eda881 100644 (file)
@@ -13,7 +13,9 @@ man_MANS = \
        lxc-ps.1 \
        lxc-cgroup.1 \
        \
-       lxc.conf.5
+       lxc.conf.5 \
+       \
+       lxc.7
 
 
 %.1 : %.sgml 
@@ -22,6 +24,9 @@ man_MANS = \
 %.5 : %.sgml 
        docbook2man $<
 
+%.7 : %.sgml 
+       docbook2man $<
+
 clean-local:
-       $(RM) manpage.* *.1 *.sgml $(man_MANS)
+       $(RM) manpage.* *.7 *.5 *.1 *.sgml $(man_MANS)
 endif
\ No newline at end of file
index 26938efa9bdd7369129b22fcc3e6889b75cb51c2..556767591aabfc87481f45b6e6544d13d978df08 100644 (file)
@@ -49,11 +49,9 @@ int lxc_start(const char *name, char *argv[])
 {
        char init[MAXPATHLEN];
        char *val = NULL;
-       char ttyname[MAXPATHLEN];
        int fd, lock, sv[2], sync = 0, err = -LXC_ERROR_INTERNAL;
        pid_t pid;
        int clone_flags;
-       ssize_t n;
 
        lock = lxc_get_lock(name);
        if (lock < 0) {
@@ -66,17 +64,11 @@ int lxc_start(const char *name, char *argv[])
 
        /* Begin the set the state to STARTING*/
        if (lxc_setstate(name, STARTING)) {
-               lxc_log_error("failed to set state '%s'", lxc_state2str(STARTING));
+               lxc_log_error("failed to set state '%s'", 
+                             lxc_state2str(STARTING));
                goto out;
        }
 
-       n = readlink("/proc/self/fd/0", ttyname, sizeof(ttyname));
-       if (n < 0) {
-               lxc_log_syserror("failed to read '/proc/self/fd/0'");
-               goto out;
-       }
-       ttyname[n] = '\0';
-
        /* Synchro socketpair */
        if (socketpair(AF_LOCAL, SOCK_STREAM, 0, sv)) {
                lxc_log_syserror("failed to create communication socketpair");
@@ -128,11 +120,6 @@ int lxc_start(const char *name, char *argv[])
                        goto out_child;
                }
 
-               if (mount(ttyname, "/dev/console", "none", MS_BIND, 0)) {
-                       lxc_log_syserror("failed to mount '/dev/console'");
-                       goto out_child;
-               }
-
                if (prctl(PR_CAPBSET_DROP, CAP_SYS_BOOT, 0, 0, 0)) {
                        lxc_log_syserror("failed to remove CAP_SYS_BOOT capability");
                        goto out_child;