]> git.proxmox.com Git - mirror_lxc.git/commit - src/lxc/conf.c
print a helpful message if creating unpriv container with no idmap
authorSerge Hallyn <serge.hallyn@ubuntu.com>
Tue, 29 Jul 2014 18:26:29 +0000 (18:26 +0000)
committerStéphane Graber <stgraber@ubuntu.com>
Thu, 31 Jul 2014 18:17:04 +0000 (14:17 -0400)
commit97e9cfa02ff30cbbc305e745559ab62ce90efd81
treeb55106b99a7827a2033f1b781accf7e3ff1112b0
parent719fae07bf641ad6ed80b12c52f60b68d734f611
print a helpful message if creating unpriv container with no idmap

This gives me:

ubuntu@c-t1:~$ lxc-create -t download -n u1
lxc_container: No mapping for container root
lxc_container: Error chowning /home/ubuntu/.local/share/lxc/u1/rootfs to container root
lxc_container: You must either run as root, or define uid mappings
lxc_container: To pass uid mappings to lxc-create, you could create
lxc_container: ~/.config/lxc/default.conf:
lxc_container: lxc.include = /etc/lxc/default.conf
lxc_container: lxc.id_map = u 0 100000 65536
lxc_container: lxc.id_map = g 0 100000 65536
lxc_container: Error creating backing store type (none) for u1
lxc_container: Error creating container u1

when I create a container without having an id mapping defined.

Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
src/lxc/conf.c
src/lxc/conf.h
src/lxc/lxc_usernsexec.c
src/lxc/lxccontainer.c