vagrant: Get vagrant up and running with lxc 3.0.0

This commit is contained in:
Puneeth Chaganti 2018-05-03 08:21:26 +05:30 committed by Tim Abbott
parent 8fe54a533a
commit e6ac98cc9b
1 changed files with 4 additions and 1 deletions

5
Vagrantfile vendored
View File

@ -126,11 +126,14 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.provider "lxc" do |lxc|
if command? "lxc-ls"
LXC_VERSION = `lxc-ls --version`.strip unless defined? LXC_VERSION
if LXC_VERSION >= "1.1.0"
if LXC_VERSION >= "1.1.0" and LXC_VERSION < "3.0.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
if LXC_VERSION >= "3.0.0"
lxc.customize 'apparmor.allow_incomplete', 1
end
if LXC_VERSION >= "2.0.0"
lxc.backingstore = 'dir'
end