-
Notifications
You must be signed in to change notification settings - Fork 181
aa_allow_incomplete required on Ubuntu 14.10 #333
Comments
I also had to add that option on Ubuntu 14.10. |
I'm not sure what is the best way to solve this, lemme think a bit more and get a 14.10 host ready to test things out. |
Confirmed that this is an issue on Ubuntu 14.10. Does anyone know why is that needed? |
The change to the Vagrantfile is also breaking provisioning for < 14.10. Actually breaking LXC at a whole for the container ( |
Looks like that config was introduced on lxc 1.1.0.alpha2: lxc/lxc@7aff4f4 Which lxc version have you guys got up there? |
Just to make things clear: @jvanoostveen that is kinda of expected because you are probably using a lxc version that does not support that config. |
That might be true, but it makes it hard to commit this line in the repository. The version installed on my system is |
Yup, I'm not planning to add any logic around this to the plugin right now since it is not required on pre 1.1.0 (which is what I believe most people are still using these days as 1.0.X is what ships on 14.04 LTS) Tagged this as a documentation change so it reminds me of adding instructions around this to the README. |
I added a check for the LXC version to the LXC_VERSION = `lxc-ls --version`.strip
Vagrant.configure("2") do |config|
config.vm.box = "trusty64"
config.vm.provider :lxc do |lxc|
if LXC_VERSION != '1.0.6'
lxc.customize 'aa_allow_incomplete', '1'
end
lxc.customize 'network.mtu','1400'
end
end You could make the comparison a bit more intelligent, but this worked for what I needed. |
This seems to work: LXC_VERSION = `lxc-ls --version`.strip unless defined? LXC_VERSION
if LXC_VERSION >= "1.1.0"
# Allow start without AppArmor, otherwise Box will not Start on Ubuntu 14.10
# see https://github.com/fgrehm/vagrant-lxc/issues/333
lxc.customize 'aa_allow_incomplete', 1
end |
Cool, and what you guys described can be easily added to the global |
Things like this should work out of the box don't you think? |
It might... I need some time to better understand what that flag is actually doing, in the meantime, lxc 1.1.0+ users can work around that by adding the following to Vagrant.configure("2") do |config|
config.vm.provider :lxc do |lxc|
lxc.customize 'aa_allow_incomplete', 1
end
end |
If anyone uses test-kitchen https://github.com/test-kitchen/test-kitchen with vagrant-lxc and your containers require
driver_plugin: lxc
driver:
name: vagrant
provider: lxc
customize:
aa_allow_incomplete: 1
- name: debian.7-lxc
platform: linux
driver:
box: debian7lxc
driver_config:
username: root # defaults to "root"
password: root # defaults to "root"
suites:
- name: api
Of course you can also use per specific platform/suite overrides, refer to test-kitchen docs. |
Hey, sorry for the silence here but this project is looking for maintainers 😅 As per #499, I've added the |
I had to add this to my Vagrantfile to allow it to work with a Ubuntu 14.10 host
The text was updated successfully, but these errors were encountered: