Commit graph

26 commits

Author SHA1 Message Date
Virgil Dupras
a1aa60ded5 Remove supports_attach? and call to /sbin/halt
Hosts without support for lxc-attach are ancien and can always use old
versions of vagrant-lxc. To be able to move forward more easily, we
should be able to assume a functional `lxc-attach`.

As for `/sbin/halt`, I'm really not sure it's needed anymore. Let's see
if its removal causes problems.
2018-07-24 11:21:09 -04:00
Virgil Dupras
2b08ae199f driver: little cleanup after LXC 1.0+ requirement bump
The conditional `lxc-version` and `lxc-config` mechanisms aren't needed
anymore. They were for pre-1.0 LXC versions.
2018-01-13 20:34:41 -05:00
Virgil Dupras
aa777653f4 Use lxc-info instead of lxc-attach to retrieve container IP
`lxc-info -iH` to retrieve IP address was not available in early LXC
development but was there at LXC 1.0. Because we've bumped our minimum
LXC requirement to v1.0 recently, we can simplify the IP retrieval
process and also get rid of the `dnsmasq` fallback.
2018-01-13 15:53:28 -05:00
Fabio Rehm
156bc015c8 Allow backingstore options to be used along with the sudo wrapper script [GH-310] 2015-01-14 21:07:35 -02:00
Fabio Rehm
2f0eccb236 🔨 Fix the build 🔨 2014-10-15 01:14:52 -03:00
Azamat Khudaygulov
f454924a59 The path of storage containers taken from lxc-config, instead of using a constant for lxc>=1.0.0.
* for lxc to 1.0.0 using constant Vagrant::LXC::Driver::DEFAULT_CONTAINERS_PATH
 * change method Vagrant::LXC::Driver::CLI#version to call lxc-create if lxc-version command not exists (to lxc version 1.0.0)
2014-09-23 16:07:03 +04:00
Fabio Rehm
80d54bb261 Fix the build 2014-07-24 21:58:04 -03:00
Fabio Rehm
235f268942 Backport some specs 2014-06-08 22:52:33 -03:00
Fabio Rehm
b17fb7baa8 Fix broken specs 2014-05-04 20:50:04 -03:00
Fabio Rehm
2e2c2fad56 Convert specs to RSpec 2.99.0.beta2 syntax with Transpec
This conversion is done by Transpec 1.10.2 with the following command:
    transpec

* 46 conversions
    from: obj.should
      to: expect(obj).to

* 20 conversions
    from: obj.stub(:message)
      to: allow(obj).to receive(:message)

* 10 conversions
    from: == expected
      to: eq(expected)

* 6 conversions
    from: obj.should_receive(:message)
      to: expect(obj).to receive(:message)

* 5 conversions
    from: obj.should_not
      to: expect(obj).not_to

* 5 conversions
    from: Klass.any_instance.stub(:message) { |arg| }
      to: Klass.any_instance.stub(:message) { |instance, arg| }

* 5 conversions
    from: Klass.any_instance.stub(:message)
      to: allow_any_instance_of(Klass).to receive(:message)

* 1 conversion
    from: lambda { }.should
      to: expect { }.to
2014-03-14 11:38:54 -03:00
Fabio Rehm
aef40d5b42 core: Fix tests to be rspec 3.0 compatible [GH-111] 2014-03-13 00:57:36 -03:00
Fabio Rehm
44f00bd7ed Add spec to check if container state detection is case insentive [GH-217] 2014-02-12 01:47:23 -02:00
Fabio Rehm
7e00b96520 Show something meaningful to the user in case the container already exists [GH-132] 2014-02-02 19:27:08 -02:00
Fabio Rehm
2b062487bc Hack in a fix for hosts that do not have lxc-shutdown around [GH-150] 2013-10-24 11:47:15 -02:00
Vokhmin Alexey V
39515cc1da #157: small refactoring, updated specs 2013-10-12 02:15:12 +04:00
Fabio Rehm
c194b3a24a Fix lxc-attach --namespaces support detection and cache the result 2013-10-03 13:26:04 -03:00
Fabio Rehm
ca0d8d53a5 Fix broken specs 2013-10-03 10:38:42 -03:00
Fabio Rehm
2082a5a81d Remove some unused args and add pending specs so that we don't forget to test it 2013-07-31 22:35:49 -03:00
Fabio Rehm
d62a053674 Add support for using a sudo wrapper script
Closes #90
2013-07-28 02:17:07 -03:00
Fabio Rehm
3e73a85d52 Enable retries when fetching container state
Fixes #74
2013-07-08 13:05:43 -03:00
Fabio Rehm
51d26b00cd Clean up the mess I left behind 2013-06-08 02:01:50 -03:00
Fabio Rehm
3cca168248 Stop container with lxc-stop if lxc-shutdown does not succeed 2013-05-07 11:07:35 -03:00
Fabio Rehm
dd5c1b1c6b Add support for reading installed lxc version from cli object 2013-04-08 22:29:06 -03:00
Fabio Rehm
ee9bfa4189 Config#start_opts -> Config#customize 2013-04-05 22:10:49 -03:00
Fabio Rehm
14f769ee0d Remove support for setting target rootfs path 2013-04-05 22:10:48 -03:00
Fabio Rehm
082f7dc5d3 Rename Container to Driver 2013-04-05 22:10:48 -03:00
Renamed from spec/unit/container/cli_spec.rb (Browse further)