0x0916
935cfd3e36
testcase: define a network before checks
...
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-29 13:18:41 +08:00
0x0916
ae1dc8b42e
confile_utils: supporting new net hwaddr key in update_hwaddr
...
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-29 13:18:41 +08:00
0x0916
4a787c27b2
confile: supporting new net hwaddr key in network_new_hwaddrs
...
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-29 13:18:41 +08:00
0x0916
ce4be612ce
confile_utils: add lxc_config_net_hwaddr
...
`lxc_config_net_hwaddr` return true if the config entry
is `lxc.network.hwaddr` or `lxc.net.[i].hwaddr`, `lxc.network.[i].hwaddr`
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-29 13:18:41 +08:00
0x0916
82c3a0dc57
confile: update comment: replace p+12 with p+8
...
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-29 13:18:41 +08:00
0x0916
7fa3f2e9eb
replace all lxc.network* with lxc.net*
...
This patch wipe all references to lxc.network{[i]}.*
and replace with lxc.net.{[i]}.* in templates, documentation
and configuration files.
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-29 13:18:41 +08:00
Christian Brauner
18ede42752
Merge pull request #1652 from 0x0916/2017-06-27/free-downscript
...
confile: free netdev->downscript
2017-06-27 21:14:45 +02:00
0x0916
e07629138f
confile: free netdev->downscript
...
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-27 22:12:38 +08:00
Christian Brauner
3129a46f47
Merge pull request #1650 from 0x0916/2017-06-27/refactor-confile-code
...
refactor confile code
2017-06-27 10:43:35 +02:00
0x0916
71e287cad3
refactor confile code
...
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-27 15:54:23 +08:00
Serge Hallyn
c949f5cc0e
Merge pull request #1639 from brauner/2017-06-23/lxc_2_1_preparations
...
confile: prepare for 2.1.
2017-06-26 09:13:47 -05:00
Christian Brauner
a3711f5246
Merge pull request #1648 from 0x0916/remove-__func__
...
remove the `__func__` macro
2017-06-26 14:29:23 +02:00
Christian Brauner
d6cb82ac01
Merge pull request #1647 from 0x0916/update-api-doc
...
API doc: update note for get_config_item
2017-06-26 12:03:42 +02:00
0x0916
b103ceac2c
remove the __func__
macro
...
Our logging function will always spew out the function name.
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-26 17:55:12 +08:00
0x0916
13a4215bfb
API doc: update note for get_config_item
...
Fix issue: https://github.com/lxc/lxc/issues/505
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-26 17:33:10 +08:00
Christian Brauner
488364568d
Merge pull request #1644 from evgeni/centos-7
...
default to CentOS 7
2017-06-25 10:00:30 +02:00
Christian Brauner
79aa9f9f44
Merge pull request #1643 from evgeni/aarch64
...
templates/debian: add aarch64 → arm64 mapping
2017-06-24 19:37:38 +02:00
Christian Brauner
cb54b5798a
Merge pull request #1645 from evgeni/centos-altarch
...
use altarch mirror for CentOS on arches other than i386 and x86_64
2017-06-24 19:37:25 +02:00
Evgeni Golov
e54bd54f5a
use altarch mirror for CentOS on arches other than i386 and x86_64
...
CentOS only has i386 and x86_64 listed in mirrorlist.centos.org,
use http://mirror.centos.org/altarch/ for all other arches instead
See: https://bugs.centos.org/view.php?id=11250
Signed-off-by: Evgeni Golov <evgeni@debian.org>
2017-06-24 19:32:17 +02:00
Evgeni Golov
420382d598
default to CentOS 7
...
Signed-off-by: Evgeni Golov <evgeni@debian.org>
2017-06-24 18:56:22 +02:00
Evgeni Golov
2c66050352
templates/debian: add aarch64 → arm64 mapping
...
uname -m reports aarch64, but Debian calls the arch arm64
Signed-off-by: Evgeni Golov <evgeni@debian.org>
2017-06-24 18:40:39 +02:00
Christian Brauner
58c89a1422
Merge pull request #1635 from 0x0916/instead-of-strerror
...
Use strerror(errno) instead of %m
2017-06-23 18:10:46 +02:00
Christian Brauner
a0075d68b1
Merge pull request #1640 from 0x0916/update-ignore-file
...
update .gitignore
2017-06-23 18:00:10 +02:00
0x0916
58e49ed2c7
update .gitignore
...
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-23 23:17:29 +08:00
0x0916
13277ec49c
Use strerror(errno) instead of %m
...
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-23 23:10:49 +08:00
Christian Brauner
39b8f404dc
confile: remove lxc.pivotdir
...
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-23 16:00:24 +02:00
Christian Brauner
26a38fb6aa
confile: remove lxc.kmsg
...
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-23 16:00:23 +02:00
Christian Brauner
953fe44f7c
confile: properly namespace security keys
...
- lxc.aa_profile => lxc.apparmor.profile
- lxc.aa_allow_incomplete => lxc.apparmor.allow_incomplete
- lxc.se_context => lxc.selinux.context
The legacy keys will be kept around until LXC 3.0 and then will be removed.
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-23 15:37:55 +02:00
Christian Brauner
af36a8ee9c
Merge pull request #1638 from 0x0916/fix-memory-resource-leak
...
fix memory and resource leak
2017-06-23 15:34:15 +02:00
Christian Brauner
a7ff221374
Merge pull request #1637 from 0x0916/fix-lxc.pc
...
Revert "Add a prefix to the lxc.pc"
2017-06-23 14:44:12 +02:00
0x0916
17ac53014b
fix memory and resource leak
...
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-23 20:40:29 +08:00
0x0916
4d628ca896
Revert "Add a prefix to the lxc.pc"
...
This reverts commit 758243d8af
.
Signed-off-by: 0x0916 <w@laoqinren.net>
2017-06-23 19:47:12 +08:00
Serge Hallyn
72cc48f990
Merge pull request #1632 from brauner/2017-06-19/new_network_parser_part_deux
...
network: new network parser part II
2017-06-21 10:30:58 -05:00
Christian Brauner
1ecd12ca1e
Merge pull request #1633 from lifeng68/Fix_memory_leak
...
Fix memory leak of 'lxc_tty_state'
2017-06-21 11:54:20 +02:00
Christian Brauner
ab6faf2ed3
confile: do not check for empty value twice
...
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-21 11:13:57 +02:00
Li Feng
0e6da90bc0
Fix memory leak of 'lxc_tty_state'
...
Signed-off-by: Li Feng <lifeng68@huawei.com>
2017-06-21 13:38:06 +08:00
Christian Brauner
b61bb54042
network: test legacy index based networks
...
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-21 00:44:17 +02:00
Christian Brauner
872e772da6
network: return negative idx for legacy networks
...
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-21 00:29:09 +02:00
Christian Brauner
01aebbc375
network: test new network configuration parser
...
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-20 13:13:21 +02:00
Christian Brauner
f9373e40b3
network: new network parser part II
...
Serge and I discussed the new network parser we've merge a couple of days ago.
He pointed out that a bunch of use-cases we're currently supporting in the old
network parser would be broken by the new parser. As we've pointed out many
times before, we're strongly commited to backwards compatibility and not
breaking existing use-cases. That's why we decided to take a new approach.
Instead of trying to mangle the old parser and new parser to come up with
something that allows a smooth transition we will simply deprecate the old
configuration keys with LXC 3.0. In the meantime we will support the full-blown
old legacy parser and the new network parser. Specifically, this means that
we're deprecating:
lxc.network.*
in favor of
lxc.net.*
With LXC 2.1. defining networks using lxc.network.* keys will cause a
deprecation warning to be shown/logged. We strongly suggest that users upgrade
their existing configuration files to switch to the new network configuration
parser. Starting with LXC 3.0 we will remove all lxc.network.* keys and will
only support lxc.net.* style network configurations.
Note that the new network configuration parser will only accept index based
configuration keys, i.e. we are only support lxc.net.[i].* keys without an
index such as lxc.net.type are not supported anymore. The advantages of this
approach are vast. Not just internally, but also user-facing since it is much
clearer what configuration key belongs to what network.
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-20 13:13:20 +02:00
Christian Brauner
4331b86a16
Merge pull request #1631 from tenforward/japanese
...
Update Japanese lxc.container.conf(5)
2017-06-20 10:46:42 +02:00
KATOH Yasufumi
50a8555e99
doc: Untabify Japanese lxc.container.conf(5)
...
Tab and white space is mixed in Japanese lxc.container.conf(5), so
unify into the white space.
Signed-off-by: KATOH Yasufumi <karma@jazz.email.ne.jp>
2017-06-20 17:36:30 +09:00
KATOH Yasufumi
2513f519cb
doc: Tweak Japanese lxc.container.conf(5)
...
Add description of new network configuration, and tweak.
Update for commit b9986e437b
Signed-off-by: KATOH Yasufumi <karma@jazz.email.ne.jp>
2017-06-20 17:28:49 +09:00
Serge Hallyn
842404a7f3
Merge pull request #1630 from brauner/2017-06-20/fix_siblk_detection
...
utils: use 1LU otherwise we overflow
2017-06-19 20:30:16 -05:00
Christian Brauner
6fbcbe3bd7
utils: use 1LU otherwise we overflow
...
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-20 02:48:47 +02:00
Christian Brauner
71e4d99cab
Merge pull request #1628 from tanyifeng/fix_detect_way_of_bitmask
...
utils: fix the way to detect blocking signal
2017-06-19 08:05:02 +02:00
Yifeng Tan
455f2b20ed
utils: fix the way to detect blocking signal
...
Signed-off-by: Yifeng Tan <tanyifeng1@huawei.com>
2017-06-19 18:36:13 +08:00
Serge Hallyn
d21c360988
Merge pull request #1626 from brauner/2017-06-13/new_networks_parser
...
new network config parser
2017-06-18 17:24:27 -05:00
Christian Brauner
ce49441853
confile: adapt warning
...
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-19 00:10:21 +02:00
Christian Brauner
d1826cf12d
network: refuse to create unsupported net types
...
Containers setup by unprivileged users are only able to create veth network
types.
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
2017-06-18 23:44:52 +02:00