Commit Graph

791 Commits

Author SHA1 Message Date
David Gageot 6a5cc751bb FIX #2232 Check that the user is an Administrator
Signed-off-by: David Gageot <david@gageot.net>
2015-12-23 12:04:44 +01:00
David Gageot d5e11fb961 FIX #512 Check the virtual switch in PreCreateCheck()
Signed-off-by: David Gageot <david@gageot.net>
2015-12-23 12:04:39 +01:00
David Gageot aa3a4e4498 Simplify code
Signed-off-by: David Gageot <david@gageot.net>
2015-12-23 11:38:51 +01:00
David Gageot 2311fd69c9 Format code
Signed-off-by: David Gageot <david@gageot.net>
2015-12-23 11:36:40 +01:00
David Gageot 19fc64d583 Remove redundant code
Signed-off-by: David Gageot <david@gageot.net>
2015-12-23 11:31:38 +01:00
Fabio Rapposelli 2e90b7cb55 Update vSphere driver to work with govmomi instead of wrapping govc.
Signed-off-by: Fabio Rapposelli <fabio@vmware.com>
2015-12-22 19:00:45 +01:00
David Gageot ee8c9abed2 Merge pull request #2654 from dgageot/2140_driver_restart
Change host restart to use the driver implementation
2015-12-22 14:32:49 +01:00
Jean-Laurent de Morlhon e22f1db4bf Merge pull request #2657 from dgageot/improve-generic-driver
Improve generic driver
2015-12-22 14:13:22 +01:00
Jean-Laurent de Morlhon 643df3c0a7 Merge pull request #2589 from boyvinall/mv/filter-openstack-floating
Filter openstack floating IPs by tenant ID
2015-12-22 14:12:21 +01:00
David Gageot cdfa729f36 Simplify code
Signed-off-by: David Gageot <david@gageot.net>
2015-12-22 12:04:46 +01:00
David Gageot 181a1d47b4 The generic driver shouldn't support kill since stop is not supported
Signed-off-by: David Gageot <david@gageot.net>
2015-12-22 11:46:59 +01:00
David Gageot 4bfd8ab4c1 Remove dead code in generic driver
Signed-off-by: David Gageot <david@gageot.net>
2015-12-22 11:46:14 +01:00
David Gageot 1c6ceed28e Fix Restart() for some drivers
Signed-off-by: David Gageot <david@gageot.net>
2015-12-22 10:32:57 +01:00
David Gageot 6f8a6dd272 FIX #2641 Digital Ocean Custom SSH port
Signed-off-by: David Gageot <david@gageot.net>
2015-12-21 16:16:33 +01:00
David Gageot df30a135b2 Merge pull request #2644 from dgageot/nathanleclaire-xtra_vbox_logs
Add extra logging to VirtualBox driver
2015-12-21 09:46:31 +01:00
David Gageot c584b8e641 Merge pull request #2625 from dgageot/2624-reject-duplicate-hostonlyifs
FIX #2624 reject duplicate hostonlyifs name/IP
2015-12-21 09:29:25 +01:00
Nathan LeClaire 54bda622d3 Add extra logging to VirtualBox driver
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-12-21 09:20:53 +01:00
David Gageot 352d28220c Merge pull request #2620 from dgageot/2619-hardware-virtualization-test
Don't create the VM if no hardware virtualization
2015-12-21 09:18:49 +01:00
David Gageot 3c4fd63f93 FIX #2624 reject duplicate hostonlyifs name/IP
Signed-off-by: David Gageot <david@gageot.net>
2015-12-21 09:15:01 +01:00
Nathan LeClaire 204af9fe5e Merge pull request #2618 from dgageot/2189-update-b2d-cache-in-precreatecheck
Update b2d cache in PreCreateCheck
2015-12-18 16:51:56 -08:00
David Gageot dd379d33c8 FIX #2617 Check hostonlyif after its creation
Signed-off-by: David Gageot <david@gageot.net>
2015-12-18 17:44:52 +01:00
David Gageot ac45f88ce3 Don't create the VM if no hardware virtualization
Signed-off-by: David Gageot <david@gageot.net>
2015-12-18 12:27:04 +01:00
David Gageot a7bd9e06d2 Update B2D cache in PreCreateCheck phase
Signed-off-by: David Gageot <david@gageot.net>
2015-12-18 11:14:59 +01:00
Matt Vinall 0815379c26 Filter openstack floating IPs by tenant ID
Merge j2sol:filter-openstack-floating and fix up for comments in PR #1809.

Signed-off-by: Matt Vinall <matt.vinall@imgtec.com>
2015-12-15 22:30:49 +00:00
David Gageot b995a4d65a FIX #2561 SSH pubkey should have username comment
Signed-off-by: David Gageot <david@gageot.net>
2015-12-15 11:12:53 +01:00
Nathan LeClaire d29a42ebc6 Merge pull request #1299 from hairyhenderson/ssh-agent-support-1291
Allowing generic driver to use ssh-agent to get identities
2015-12-11 17:31:55 -08:00
David Gageot f3775f774c FIX #2553 Fusion Driver is supported only on darwin
Signed-off-by: David Gageot <david@gageot.net>
2015-12-11 15:46:47 +01:00
David Gageot 42ad416c0a FIX #2479 Warn on VirtualBox version
Signed-off-by: David Gageot <david@gageot.net>
2015-12-10 16:10:52 +01:00
Jean-Laurent de Morlhon cc6dc7c1be Merge pull request #2545 from dgageot/1432-google-update-firewall
Google driver - Update firewall open ports
2015-12-10 14:31:08 +01:00
David Gageot 82edc1d174 FIX #1432 open all the ports need for google driver
Signed-off-by: David Gageot <david@gageot.net>
2015-12-10 14:20:46 +01:00
David Gageot 58b4cce392 Remove dead code and other cosmetic changes
Signed-off-by: David Gageot <david@gageot.net>
2015-12-10 14:20:46 +01:00
David Gageot 8a64fd4716 Merge pull request #2528 from jhoos/vmwarefusion-umask
Explicitly set umask before invoking vmrun in vmwarefusion
2015-12-10 09:24:09 +01:00
Dave Henderson cf6136fed0 Allowing generic driver to use ssh-agent to get identities
Signed-off-by: Dave Henderson <dhenderson@gmail.com>
2015-12-09 09:36:08 -05:00
Jason Hoos d5ff6b21ea Explicitly set umask before invoking vmrun in vmwarefusion
For some reason, invoking vmrun with the nogui option doesn't
work right if umask is set to not allow world-readable permissions
by default.  This seems to be true at least in VMware Fusion 7.0.x
through 8.0.1.  As a workaround, the driver now explicitly sets
the umask to 022 before invoking vmrun.

Signed-off-by: Jason Hoos <jhoos@maestrohealth.com>
2015-12-08 11:45:38 -06:00
David Gageot 52128128fd Detect Yet Another Virtualization issue
Signed-off-by: David Gageot <david@gageot.net>
2015-12-08 17:43:39 +01:00
Jean-Laurent de Morlhon 1079735af8 Remove withFields
Signed-off-by: Jean-Laurent de Morlhon <jeanlaurent@morlhon.net>
2015-12-07 10:34:43 +01:00
Jean-Laurent de Morlhon 760e814d43 Merge pull request #2501 from fsoppelsa/2478-sanitizekey
Sanitize keynames by replacing dots with underscores
2015-12-07 09:41:34 +01:00
Lars Kanis 850e2646a6 Fix detection of virtualisation support on AMD CPU.
This also changes the amd test case to /proc/cpuinfo content of
a real AMD CPU.

Signed-off-by: Lars Kanis <lars@greiz-reinsdorf.de>
2015-12-07 07:39:24 +01:00
Fabrizio 6e43436a3d Sanitize keynames by replacing dots with underscores
Signed-off-by: Fabrizio Soppelsa <fsoppelsa@mirantis.com>
2015-12-05 16:04:35 -08:00
Nathan LeClaire dac327f167 Merge pull request #2488 from trecloux/2361-ubuntu-15.10-base-images
Update default images to ubuntu 15.10
2015-12-04 13:51:59 -08:00
Thomas Recloux bd12140d6b Google : update default image to ubuntu 15.10
Signed-off-by: Thomas Recloux <thomas.recloux@gmail.com>
2015-12-03 19:14:14 +01:00
Thomas Recloux 697b543789 Rackspace : update default image to ubuntu 15.10
Signed-off-by: Thomas Recloux <thomas.recloux@gmail.com>
2015-12-03 19:14:14 +01:00
Thomas Recloux ca7ea324c4 Exoscale : update default image to ubuntu 15.10
Signed-off-by: Thomas Recloux <thomas.recloux@gmail.com>
2015-12-03 19:14:14 +01:00
Thomas Recloux 73ddbe02ac DigitalOcean : update default image to ubuntu 15.10
Signed-off-by: Thomas Recloux <thomas.recloux@gmail.com>
2015-12-03 19:14:14 +01:00
Thomas Recloux 977fa7e48f Azure : update default image to ubuntu 15.10
Signed-off-by: Thomas Recloux <thomas.recloux@gmail.com>
2015-12-03 19:14:08 +01:00
Thomas Recloux 0408378332 AWS : update default images to ubuntu 15.10
Signed-off-by: Thomas Recloux <thomas.recloux@gmail.com>
2015-12-03 14:50:21 +01:00
Fabio Rapposelli 2dcfcf2b06
Fix for vSphere driver boot2docker ISO issues
Fixes #2279 #2060

Signed-off-by: Fabio Rapposelli <fabio@vmware.com>
2015-12-03 07:24:26 -05:00
David Gageot 029b39ee62 Merge pull request #2141 from janeczku/digitalocean-userdata
Digitalocean driver: Support for creating Droplets with Cloud-init User Data
2015-12-03 10:53:06 +01:00
Joe Friedl b2c9366245 Add the --virtualbox-host-dns-resolver flag
Signed-off-by: Joe Friedl <joe@joefriedl.net>
2015-12-01 21:03:51 -05:00
Jan Broer 59d7c3ca61 Enhances Digitalocean driver to support creating Droplets with user-data
Signed-off-by: Jan Broer <janeczku@yahoo.de>
2015-12-01 21:22:26 +01:00
Jean-Laurent de Morlhon b7b767aafe Allow virtualbox DNSProxy override
Signed-off-by: Jean-Laurent de Morlhon <jeanlaurent@morlhon.net>
2015-12-01 16:02:20 +01:00
Fabio Rapposelli 40aab51e6a
Add id/gid option to mount when using vmhgfs
Signed-off-by: Fabio Rapposelli <fabio@vmware.com>
2015-12-01 05:47:37 +01:00
David Gageot f00b0b83cf Merge pull request #2458 from jeanlaurent/typo
Typo in EC2 Driver
2015-11-30 17:37:30 +01:00
Jean-Laurent de Morlhon 6d5bc99387 Typo
Signed-off-by: Jean-Laurent de Morlhon <jeanlaurent@morlhon.net>
2015-11-30 17:23:11 +01:00
David Gageot ec76843e03 Cosmetics
Signed-off-by: David Gageot <david@gageot.net>
2015-11-30 14:24:58 +01:00
David Gageot fea0dcb3da Simpler error message
Signed-off-by: David Gageot <david@gageot.net>
2015-11-30 14:24:58 +01:00
David Gageot 77b7734404 Simplify code
Signed-off-by: David Gageot <david@gageot.net>
2015-11-30 14:24:58 +01:00
David Gageot 085fe1334a Faster google driver
Signed-off-by: David Gageot <david@gageot.net>
2015-11-30 14:24:57 +01:00
Jean-Laurent de Morlhon e0998d030b Merge pull request #2433 from dgageot/generic-driver
Improve Generic driver
2015-11-27 10:18:01 +01:00
David Gageot 55ecd6561c Add env variables to generic driver
Signed-off-by: David Gageot <david@gageot.net>
2015-11-27 09:58:40 +01:00
David Gageot 7d6bfffb8f Generic Driver - Check key in PreCheck
Signed-off-by: David Gageot <david@gageot.net>
2015-11-27 09:39:15 +01:00
David Gageot 515bdad0f6 Remove redundant log
Signed-off-by: David Gageot <david@gageot.net>
2015-11-27 09:33:21 +01:00
David Gageot 6a1993664d FIX #1619 Timeout test for machine ls
Signed-off-by: David Gageot <david@gageot.net>
2015-11-26 08:49:56 +01:00
David Gageot 742cdb958b Add more command tests
Signed-off-by: David Gageot <david@gageot.net>
2015-11-25 14:23:29 +01:00
Nathan LeClaire 47da7f8314 Add interfaces for CLI unit testing and env test
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-11-24 18:09:27 -08:00
Nathan LeClaire 7b483fe0ee Revise CommandLine interface to contain libmachine client and store
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-11-24 09:59:58 -08:00
David Gageot d65e23600e Merge pull request #2402 from jeanlaurent/os-specific
Add test on os specific code
2015-11-24 18:02:17 +01:00
Jean-Laurent de Morlhon b7745d7bc4 Add Test on VTX Detection
Signed-off-by: Jean-Laurent de Morlhon <jeanlaurent@morlhon.net>
2015-11-24 17:40:22 +01:00
David Gageot 56665a82e4 Merge pull request #2385 from dgageot/2086-add-error-column-to-ls
Add an errors column to docker-machine ls
2015-11-24 16:23:22 +01:00
Jean-Laurent de Morlhon 84a40bcc06 Refactor OS Specific code
And introduce Per-OS testing

Signed-off-by: Jean-Laurent de Morlhon <jeanlaurent@morlhon.net>
2015-11-24 16:03:41 +01:00
David Gageot 84199a12e3 Improve test coverage
Signed-off-by: David Gageot <david@gageot.net>
2015-11-24 11:29:39 +01:00
David Gageot 9039cbba3d FIX #2086 Add an error column to ls
Signed-off-by: David Gageot <david@gageot.net>
2015-11-24 09:50:43 +01:00
Nathan LeClaire 3affe5ec25 Merge pull request #2391 from dgageot/update-dependencies-google
Update Google Driver dependencies
2015-11-23 12:15:19 -08:00
David Gageot 198ab07be0 Update digital ocean dependencies
Signed-off-by: David Gageot <david@gageot.net>
2015-11-23 18:14:58 +01:00
David Gageot 865133aa40 Update Google Driver dependencies
Signed-off-by: David Gageot <david@gageot.net>
2015-11-23 17:47:17 +01:00
Alex Crome 9abe8d9848 Clarifying description of hyperv-disk-size
Making clear the value is a maximum for a dynamic disk not the actual size of a fixed size disk.

Signed-off-by: Alex Crome <afscrome@users.noreply.github.com>
2015-11-23 16:41:45 +00:00
Nathan LeClaire 863e51709a Merge pull request #2369 from dgageot/detect-multiple-host-only
Detect multiple host only
2015-11-20 15:23:38 -08:00
David Gageot 8d47fe746e Reject VirtualBox version<=3
Signed-off-by: David Gageot <david@gageot.net>
2015-11-20 18:57:26 +01:00
David Gageot bf52eceed5 FIX #2231 - Detect duplicate interfaces
Signed-off-by: David Gageot <david@gageot.net>
2015-11-20 18:47:39 +01:00
David Gageot 35b2b042e1 Merge pull request #2374 from dgageot/more-vb-tests
Add more tests to the VirtualBox driver
2015-11-20 18:47:20 +01:00
Jean-Laurent de Morlhon ade5911b32 Fixes #2372, add test for #2356
Signed-off-by: Jean-Laurent de Morlhon <jeanlaurent@morlhon.net>
2015-11-20 17:48:53 +01:00
Jean-Laurent de Morlhon a8d9b498a4 Merge pull request #2365 from daehyeok/remove_paused_virtualbox
VirtualBox: Delete machine in 'PAUSED' state
2015-11-20 16:05:37 +01:00
David Gageot 308f9d025c Add more tests to virtualbox driver
Signed-off-by: David Gageot <david@gageot.net>
2015-11-20 15:01:55 +01:00
David Gageot bbe59b8020 Don't rely on empty lines
It could lead to creating multiple host only
interfaces

Signed-off-by: David Gageot <david@gageot.net>
2015-11-20 15:01:55 +01:00
David Gageot e812df723c Add somes tests to virtualbox driver
Signed-off-by: David Gageot <david@gageot.net>
2015-11-20 15:01:55 +01:00
David Gageot 53c5198a5a Use the passed VBoxManager
This makes the code easier to test.

Signed-off-by: David Gageot <david@gageot.net>
2015-11-20 15:01:55 +01:00
David Gageot b8c9ad071d Remove dead code in virtualbox
Signed-off-by: David Gageot <david@gageot.net>
2015-11-20 14:27:59 +01:00
Daehyeok Mun 02da868c08 VirtualBox: Delete machine in 'PAUSED' state
Signed-off-by: Daehyeok Mun <daehyeok@gmail.com>
2015-11-20 02:30:50 -07:00
Jean-Laurent de Morlhon acac5f146a Merge pull request #2197 from jviide/2196-vmwarefusion-no-share
Add a --vmwarefusion-no-share flag to disable the mounting of the /Users directory
2015-11-19 12:35:47 +01:00
David Gageot 33c71d6a8f Merge pull request #2351 from dgageot/improve-google
Improve google driver
2015-11-19 12:35:21 +01:00
jviide 9d2ebb630a Add --vmwarefusion-no-share option
Add a vmwarefusion driver flag to disable the mounting of the /Users
directory. Name it --vmwarefusion-no-share to reflect the pre-existing
virtualbox driver option --virtualbox-no-share.

Also add a corresponding environment variable FUSION_NO_SHARE.

The code is basically identical to the virtualbox driver's
implementation.

Signed-off-by: Joachim Viide <jviide@iki.fi>
2015-11-19 13:00:45 +02:00
David Gageot 71f82e86b1 Fix Typo
Signed-off-by: David Gageot <david@gageot.net>
2015-11-19 11:57:36 +01:00
David Gageot 79563b1972 Move VT-X check to PreCreateCheck
Signed-off-by: David Gageot <david@gageot.net>
2015-11-19 11:51:56 +01:00
David Gageot b586b94b13 Cosmetics
Signed-off-by: David Gageot <david@gageot.net>
2015-11-19 11:51:56 +01:00
David Gageot 620b2ed418 Add missing ENV for import-boot2docker-vm flag
Signed-off-by: David Gageot <david@gageot.net>
2015-11-19 11:51:55 +01:00
David Gageot df7212df95 Add missing ENV for no-share flag
Signed-off-by: David Gageot <david@gageot.net>
2015-11-19 11:51:55 +01:00
David Gageot 5aa2179807 GetURL() should fail is the machine is stopped
Signed-off-by: David Gageot <david@gageot.net>
2015-11-19 11:32:48 +01:00
David Gageot 01f3a45530 Update default google image
Signed-off-by: David Gageot <david@gageot.net>
2015-11-19 11:32:48 +01:00
David Gageot d56d0dc495 Remove unused constants
Signed-off-by: David Gageot <david@gageot.net>
2015-11-19 11:11:07 +01:00
David Gageot eb42133a06 Merge pull request #2122 from chantra/mount_linux
Add shared folder and virtualization check for Linux.
2015-11-18 10:12:56 +01:00
Vladimir Varankin 0735f3f447 fix drivers GetUrl to build propper IPv6 addr
Signed-off-by: Vladimir Varankin <nek.narqo+git@gmail.com>
2015-11-13 13:19:15 +03:00
Emmanuel Bretelle f9b11d7139 [linux] virtualization detection
Use ioutil and also check for smd flag

Signed-off-by: Emmanuel Bretelle <chantr4@gmail.com>
2015-11-12 23:57:42 -05:00
Kunal Kushwaha 23b5f8c99f BugFix: nil retured for string.
Build break on windows. introduced with PR #2207

Signed-off-by: Kunal Kushwaha <kushwaha_kunal_v7@lab.ntt.co.jp>
2015-11-12 16:00:32 +09:00
Olivier Gambier 89d9854943 Another pass at linting
Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-11-10 16:58:14 +01:00
David Gageot fb986b23e0 Merge pull request #2207 from jeanlaurent/1737-virtualbox-installation-path
Fix #1737 - Detect non default VirtualBox Installation Path
2015-11-10 10:02:38 +01:00
Jean-Laurent de Morlhon b6ca1035bd Fix for #1737 - Better detect non default VirtualBox Installation Path
Signed-off-by: Jean-Laurent de Morlhon <jeanlaurent@morlhon.net>
2015-11-10 09:52:38 +01:00
David Gageot a5a53bfbdd Merge pull request #2212 from nathanleclaire/b2d_regression
Fix boot2docker import regression
2015-11-07 16:13:11 +01:00
Nathan LeClaire ad757310fb Fix boot2docker import regression
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-11-06 17:10:41 -08:00
Amir Mohammad Saied a6c44f5d4e Use rackspace's specialized client
`openstack.NewDerivedDriver` sets client to `openstack.GenericClient`
therefore `rackspace.Client` is getting ignored.

`rackspace.Client.Authenticate` has different semantics than
`openstack.GenericClient.Authenticate`, thus almost all operations with
`rackspace` driver fail at the moment.

Signed-off-by: Amir Mohammad Saied <amirsaied@gmail.com>
2015-11-06 18:30:31 +00:00
David Gageot 4ac76457f9 Merge pull request #2199 from nathanleclaire/none_running
Change default state of none driver to state.Running
2015-11-06 07:59:49 +01:00
Nathan LeClaire ac6a18ba25 Change none default state to Running
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-11-05 18:37:15 -08:00
Olivier Gambier d2ada6488c Lint
Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-11-05 13:34:07 -08:00
David Gageot 11922080a1 FIX #2171 Fix faulty flag and add tests for SetConfigFromFlags
Signed-off-by: David Gageot <david@gageot.net>
2015-11-05 18:57:03 +01:00
Nathan LeClaire 6be950f1c0 Merge pull request #2117 from dmp42/08-carry-on-2033
Carry on commits from #2033
2015-11-04 16:41:40 -08:00
Olivier Gambier 34ee11e51d Merge pull request #2116 from dgageot/1628-oauth2
Move `goauth2/oauth` dependency to `golang.org/x/oauth2`
2015-11-04 08:54:20 -08:00
David Gageot 840ed7cc15 Migrate Digital Ocean driver to oauth2
Signed-off-by: David Gageot <david@gageot.net>
2015-11-04 10:20:44 +01:00
root d1712e0cd3 Introduced a new flag for google driver:
--google-use-internal-ip

Signed-off-by: Mariusz Woloszyn <emsi@EmsiOSX.dom.qpqp01.pl>
2015-11-04 09:10:29 +00:00
David Gageot 7f5983b703 Merge pull request #2113 from dgageot/gce-custom-images
Fixes #1243 Custom GCE images support
2015-11-04 09:00:20 +01:00
Nathan LeClaire c6d6eb863a Merge pull request #2151 from todorez/fix-ip-clash
Fix DHCP server and host-only adapter IP address clash
2015-11-03 12:06:26 -08:00
Nathan LeClaire 9a4bc9a20d Ensure that ls will still work when plugin cannot be found
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-11-03 11:35:30 -08:00
Todor Minchev 36ca9c6063 Fix DHCP server and host-only adapter IP address clash
When setting up a host-only network we need to pass the IP address
of the host adapter (e.g 192.168.99.1) to the getRandomIPinSubnet function.
Passing the network address (e.g 192.168.1.0) can result in bypassing the IP
clash check and having the same address assigned to both the DHCP server
and the host-only network interface.

Signed-off-by: Todor Minchev <todor.minchev@linux.intel.com>
2015-11-03 11:26:31 -08:00
Olivier Gambier ae2d344c2b Carry on commits from #2033
A couple of small cleanup and enhancements that were dropped after the revert.

Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-10-30 16:33:26 -07:00
David Gageot 0176f05db8 FIX #2127 Detect that HW virtualization is not supported
Signed-off-by: David Gageot <david@gageot.net>
2015-10-30 16:19:38 +01:00
Emmanuel Bretelle 42f1dbb964 virtualbox: support linux host
Fixes #2110

Signed-off-by: Emmanuel Bretelle <chantr4@gmail.com>
2015-10-29 20:21:10 -07:00
Nathan LeClaire 92d67ff13f Merge pull request #850 from dudymas/feat/openstack-nova-ip-pools
feature to fix #737 - openstack driver can use nova to allocate floating ips
2015-10-29 12:33:43 -07:00
aperepel 914ccb6968 Fixes #1243 Custom GCE images support
Signed-off-by: Andrew Grande <aprepel@gmail.com>

Signed-off-by: David Gageot <david@gageot.net>
2015-10-29 11:11:32 +01:00
David Gageot b213da0961 Use PreCreateCheck to check the project/credentials
Signed-off-by: David Gageot <david@gageot.net>
2015-10-29 10:05:24 +01:00
Nathan LeClaire 232c611464 Merge pull request #2087 from dgageot/gce-default-auth
Use Google default authentication
2015-10-28 15:18:24 -07:00
David Gageot 970c630fd3 FIX #2093 warn in case we think VT-X is not enabled.
Signed-off-by: David Gageot <david@gageot.net>
2015-10-28 22:22:04 +01:00
David Gageot 77c2bbcdd2 FIX #2023 and #1061 Use google default authentication
Signed-off-by: David Gageot <david@gageot.net>
2015-10-28 22:16:22 +01:00
Flavio Castelli 2339e548f6 Fix panic when using openstack driver
The openstack driver was unusable because some cli flags were redifined.

That caused a runtime error like:

  create flag redefined: openstack-ssh-user
  panic: create flag redefined: openstack-ssh-user

Signed-off-by: Flavio Castelli <fcastelli@suse.com>
2015-10-28 08:53:54 +01:00
David Gageot d316eb7e96 Print a better error when virtualbox fails
Instead of printing `exit status 1` we'll print
the stderr output

Signed-off-by: David Gageot <david@gageot.net>
2015-10-27 15:23:29 +01:00
David Gageot 6c5dc41e6d Revert "Remove useless duplication on GetSSHHostname"
This reverts commit b6462eb6d0.

Signed-off-by: David Gageot <david@gageot.net>
2015-10-26 18:47:14 +01:00
David Gageot 57dc1156de Revert "Remove duplication over GetIP"
This reverts commit 99aacc7b79.

Signed-off-by: David Gageot <david@gageot.net>
2015-10-26 18:47:03 +01:00
David Gageot a7559fd3a8 Revert "Generic and Base slight cleanups"
This reverts commit 19625def22.

Signed-off-by: David Gageot <david@gageot.net>
2015-10-26 18:46:54 +01:00
Nathan LeClaire 8b9291de64 Merge pull request #2033 from dmp42/03-cleanup
Code cleanup
2015-10-23 11:27:44 -07:00
Olivier Gambier 19625def22 Generic and Base slight cleanups
- tests for GetIP
- extract default values into consts (user & port)
- better error handling (cert permissions change)
- unexport Driver for generic (linting)
- ordering of methods and variables for better readability

Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-10-23 10:38:57 -07:00
Olivier Gambier 4e7f8ed7a6 Merge pull request #1856 from databus23/b2d_gh_enterprise_urls
support github enterprise urls for b2d downloads
2015-10-23 10:37:46 -07:00
Olivier Gambier 11fd9648ac Merge pull request #1639 from feelobot/validate-ec2-vpc-id-matches-subnet-id
Use SDK to Validate VpcID with SubnetId
2015-10-22 09:52:18 -07:00
Fabian Ruff 5021ffd2e7 support github enterprise urls for b2d downloads
This commit allows downloading boot2docker releases not only from the official releases url (https://api.github.com/repos/boot2docker/boot2docker/releases) but from arbitrary github repositories that publish releases with a boot2docker.iso artifact. It also supports downloading from github enterprise.

Signed-off-by: Fabian Ruff <fabian@progra.de>
2015-10-22 16:12:21 +02:00
Olivier Gambier 99aacc7b79 Remove duplication over GetIP
+ ip address proper validation

Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-10-21 13:48:13 -07:00
Olivier Gambier b6462eb6d0 Remove useless duplication on GetSSHHostname
Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-10-21 13:48:13 -07:00
Olivier Gambier c2589c8099 Trivial cleanup / ordering / inline doc
Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-10-21 13:48:13 -07:00
Olivier Gambier bf3cd8b8f4 Remove useless duplication on PreCreateCheck
Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-10-21 13:48:13 -07:00
Jeremy White f9e40c2ce2 feat(openstack): add flag for using nova networks
Signed-off-by: Jeremy White <dudymas@gmail.com>
2015-10-21 16:03:26 -04:00
Chris Abernethy 6a7c8c2a25 Additional validation on virtualbox-hostonly-cidr
Check that the CIDR provided for a virtualbox host only CIDR is specified as a host IP and netmask, e.g., 192.168.100.1/24, and not a network IP and netmask, e.g., 192.168.100.0/24. This will help prevent confusion like #1383

Signed-off-by: Chris Abernethy <cabernet@chrisabernethy.com>

Signed-off-by: David Gageot <david@gageot.net>
2015-10-21 20:46:13 +02:00
Nathan LeClaire 56acdcf5ae Merge pull request #2031 from hairyhenderson/check-vtx-darwin-1983
Adding support for darwin to IsVTXDisabled
2015-10-21 11:26:28 -07:00
David Gageot 38b7fe5013 FIX #2020 Better error when vboxmanage is missing
Signed-off-by: David Gageot <david@gageot.net>
2015-10-21 09:35:33 +02:00
Dave Henderson e2856e36f4 Adding support for darwin to IsVTXDisabled
Signed-off-by: Dave Henderson <dhenderson@gmail.com>
2015-10-20 21:20:40 -04:00
feelobot 6b7628a175 Use SDK to Validate VpcID with SubnetId
Signed-off-by: feelobot <felix.a.rod@gmail.com>
2015-10-20 12:37:33 -07:00
David Gageot 94361315a8 Add tests to virtualbox driver
Signed-off-by: David Gageot <david@gageot.net>
2015-10-20 19:08:18 +02:00
David Gageot 4a33fabe8b Check that VT-X/AMD-v is enabled
Signed-off-by: David Gageot <david@gageot.net>
2015-10-20 09:56:43 +02:00
Nathan LeClaire 447d262c06 Merge pull request #1939 from gmacario/fix-issue-1692
fix IPV6NetworkMaskPrefixLength value parsing
2015-10-19 14:17:51 -07:00
Nathan LeClaire b818d3f7e8 Merge pull request #2000 from hairyhenderson/fix-non-logf-method-calls
💄Fix log.* method calls which meant to be log.*f
2015-10-19 13:04:33 -07:00
David Arnold ab79c4d9c1 Close #2001 / consistent hyperv internal naming
Signed-off-by: David Arnold <dar@devco.co>
2015-10-18 11:53:39 -05:00
Dave Henderson 2a6e3dbf40 Fix log.* method calls which meant to be log.*f
Stuff like `log.Debug("foo bar: %s", baz)` really wants to be
`log.Debugf("foo bar: %s", baz)`...

Signed-off-by: Dave Henderson <dhenderson@gmail.com>
2015-10-17 15:59:25 -04:00
Nathan LeClaire c8edb33ecd Move towards using external binaries / RPC plugins
- First RPC steps

- Work on some flaws in RPC model

- Remove unused TLS settings from Engine and Swarm options

- Add code to correctly encode data over the network

- Add client driver for RPC

- Rename server driver file

- Start to make marshal make sense

- Fix silly RPC method args and add client

- Fix some issues with RPC calls, and marshaling

- Simplify plugin main.go

- Move towards 100% plugin in CLI

- Ensure that plugin servers are cleaned up properly

- Make flag parsing for driver flags work properly

Includes some work carried from @dmp42 updating the build process and
tests to use the new method.

Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-10-16 16:34:56 -07:00
Nathan LeClaire 600ffb7d20 Merge pull request #1968 from cmouttet/1967-openstack_InstanceIpAddress_default
add default AddressType: Fixed
2015-10-15 14:19:54 -07:00
Olivier Gambier 4c12502605 Merge pull request #1977 from dgageot/1972-fix-google-driver-tags-no-tests
Fix broken google driver
2015-10-14 10:27:42 -07:00
David Gageot 264ca68902 Fix #1972 Google drive is broken because of tags
Signed-off-by: David Gageot <david@gageot.net>
2015-10-14 09:25:44 +02:00
Christian Mouttet e256702c8c add default AddressType: Fixed
Signed-off-by: Christian Mouttet <cmouttet@gmail.com>
2015-10-10 17:19:45 +02:00
Marcel Harkema db9363ef46 Fix config drive support in VMware Fusion driver
Signed-off-by: Marcel Harkema <marcel@harkema.name>
2015-10-10 16:10:11 +02:00
Guillaume Giamarchi 6829837fd5 Add environment varibles for OpenStack flags
Some flags for the OpenStack driver did not have
a corresponding environment variable.

Among others, this is needed to run bats core tests
with the OpenStack driver.

Signed-off-by: Guillaume Giamarchi <guillaume.giamarchi@gmail.com>
2015-10-09 15:16:00 +02:00
Olivier Gambier 53658e8932 Merge pull request #1933 from hironobu-s/openstack-ip-version
Add --openstack-ip-version option
2015-10-08 16:26:08 -07:00
Hironobu Saitoh f659e817b4 Add --openstack-ip-version option
This option allows users to specify IP version.

Signed-off-by: Hironobu Saitoh <hiro@hironobu.org>
2015-10-09 07:29:48 +09:00
Nathan LeClaire 2399bfe578 Merge pull request #1952 from nathanleclaire/vbox_version
Move VBox detection to Precreate and print version
2015-10-08 11:01:31 -07:00
Nathan LeClaire 571712122d Merge pull request #1909 from skatsuta/saved-host-active
Change 'ls' to not report 'Saved' hosts as active when $DOCKER_HOST is not set
2015-10-08 11:00:45 -07:00
Soshi Katsuta 5af32bcdd3 commands: make `ls` to not report saved hosts to be active when $DOCKER_HOST is not set
Signed-off-by: Soshi Katsuta <soshi.katsuta@gmail.com>
2015-10-09 00:59:33 +09:00
Nathan LeClaire f0ebeab041 Move VBox detection to Precreate and print version
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-10-07 20:41:26 -07:00
Nathan LeClaire 94c551b964 Fix broken --storage-path flag
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-10-07 13:31:00 -07:00
Gianpaolo Macario b01442c6bb fix IPV6NetworkMaskPrefixLength value parsing #1692
Adapted from 941c70cb01

Signed-off-by: Gianpaolo Macario <gmacario@gmail.com>
2015-10-06 22:43:55 +02:00
Alexey Grachov 2992237b03 Additional info message while waiting for IP address.
It takes a lot of time to assign the IP to droplet, so informing user
about this hang looks like good idea.

Signed-off-by: Alexey Grachov <grachov.alexey@gmail.com>
2015-09-30 12:00:08 +03:00
Evan Hazlett c4cd2385bf Merge pull request #1685 from nathanleclaire/daemon_wait_over_ssh
Fix Docker daemon wait
2015-09-24 16:56:37 -04:00
Nathan LeClaire bee5cb4768 Merge pull request #1894 from dmp42/7-vbox
Fix exec error bubbling
2015-09-23 16:43:23 -07:00
Nathan LeClaire 9453df4859 Fix Docker daemon wait
Also, a few various cleanups are bundled:

1. Only call GetDriver() once to get the object in provision/utils.go
2. SSH command wrapper will return the error and let the consumer decide
   what to do with it instead of bailing automatically on non-255

Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-09-23 15:19:25 -07:00
Nathan LeClaire b5927f10c4 Make libmachine usable by outside world
- Clear out some cruft tightly coupling libmachine to filestore

- Comment out drivers other than virtualbox for now

- Change way too many things

- Mostly, break out the code to be more modular.

- Destroy all traces of "provider" in its current form.  It will be
brought back as something more sensible, instead of something which
overlaps in function with both Host and Store.

- Fix mis-managed config passthru

- Remove a few instances of state stored in env vars

- This should be explicitly communicated in Go-land, not through the
shell.

- Rename "store" module to "persist"

- This is done mostly to avoid confusion about the fact that a concrete
instance of a "Store" interface is oftentimes referred to as "store" in
the code.

- Rip out repetitive antipattern for getting store

- This replaces the previous repetive idiom for getting the cert info, and
consequently the store, with a much less repetitive idiom.

- Also, some redundant methods in commands.go for accessing hosts have
either been simplified or removed entirely.

- First steps towards fixing up tests

- Test progress continues

- Replace unit tests with integration tests

- MAKE ALL UNIT TESTS PASS YAY

- Add helper test files

- Don't write to disk in libmachine/host

- Heh.. coverage check strikes again

- Fix remove code

- Move cert code around

- Continued progress: simplify Driver

- Fixups and make creation work with new model

- Move drivers module inside of libmachine

- Move ssh module inside of libmachine

- Move state module to libmachine

- Move utils module to libmachine

- Move version module to libmachine

- Move log module to libmachine

- Modify some constructor methods around

- Change Travis build dep structure

- Boring gofmt fix

- Add version module

- Move NewHost to store

- Update some boring cert path infos to make API easier to use

- Fix up some issues around the new model

- Clean up some cert path stuff

- Don't use shady functions to get store path :D

- Continue artifact work

- Fix silly machines dir bug

- Continue fixing silly path issues

- Change up output of vbm a bit

- Continue work to make example go

- Change output a little more

- Last changes needed to make create finish properly

- Fix config.go to use libmachine

- Cut down code duplication and make both methods work with libmachine

- Add pluggable logging implementation

- Return error when machine already in desired state

- Update example to show log method

- Fix file:// bug

- Fix Swarm defaults

- Remove unused TLS settings from Engine and Swarm options

- Remove spurious error

- Correct bug detecting if migration was performed

- Fix compilation errors from tests

- Fix most of remaining test issues

- Fix final silly bug in tests

- Remove extraneous debug code

- Add -race to test command

- Appease the gofmt

- Appease the generate coverage

- Making executive decision to remove Travis coverage check

In the early days I thought this would be a good idea because it would
encourage people to write tests in case they added a new module.  Well,
in fact it has just turned into a giant nuisance and made refactoring
work like this even more difficult.

- Move Get to Load
- Move HostListItem code to CLI

Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-09-23 12:30:15 -07:00
Olivier Gambier 144b94c251 Fix error reporting on VBoxManage not found
Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-09-22 21:01:38 -07:00
Nathan LeClaire 3b85723982 Fix failing case creating host only interface
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-09-22 20:02:14 -07:00
Nathan LeClaire fe5b5cf86d Add tests for host only network retrieval feature
Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-09-22 16:29:25 -07:00
Ron Williams 0b5f4c8454 Handle bad netmask returned by virtualbox after hostonlyif creation. Fixes #1843
Signed-off-by: Ron Williams <ron.a.williams@gmail.com>
2015-09-21 14:09:29 -07:00
Olivier Gambier 5fbfbe1ff7 Rehauled build system and integration testing
- USE_CONTAINER allow to seamlessly run targets inside or outside containers
- all build calls have been harmonized, honoring the same env variables
- contributing doc has been streamlined according to that
- kill the distinction between remote and local docker builds
- got rid of some of the byzantine calls in various asorted scripts
- support for static build, debug builds, verbose

Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-09-18 15:47:00 -07:00
Nathan LeClaire b91c117238 Merge pull request #1816 from frapposelli/fusion-fuse-mount
Adding FUSE HGFS mount option
2015-09-16 16:07:31 -07:00
Nathan LeClaire 5e698f3d95 Merge pull request #1631 from dgageot/features/startstop
FIX #676 - Support Start/Stop GCE instance
2015-09-15 11:54:51 -07:00
Nathan LeClaire 207a647a40 Merge pull request #1633 from dgageot/features/tags
FIX #1297 - Support additional tags on GCE
2015-09-15 11:54:39 -07:00
David Gageot 66078be1e5 FIX #1297 - Support additional tags on GCE
Signed-off-by: David Gageot <david@gageot.net>
2015-09-15 06:56:52 +02:00
David Gageot bb45f83319 FIX #676 - Support Start/Stop GCE instance
Signed-off-by: David Gageot <david@gageot.net>
2015-09-15 06:54:53 +02:00
Matt McNaughton a0b9d179b1 Fix Go Vet errors
This commit makes no changes to code execution, but rather resolves some
`go vet` errors, the majority of which relate to `fatal` being used
instead of `fatalf` during testing.

Signed-off-by: Matt McNaughton <mattjmcnaughton@gmail.com>
2015-09-14 22:37:16 -04:00
Nathan LeClaire b52fa33056 Merge pull request #1479 from mschygulla/enhanced-vmwarefusion-driver
[Enhancement] VMware Fusion driver
2015-09-11 14:26:30 -07:00
Nathan LeClaire 7c4d0a5da7 Merge pull request #1642 from ddaze/openstack-retry
openstack: New machine active timeout parameter
2015-09-11 14:25:11 -07:00
Nathan LeClaire 5ba35ac2de Merge pull request #1812 from jclagache/master
1434-Added homebrew cask support for VMware Fusion
2015-09-11 14:21:39 -07:00
Nathan LeClaire 1b0042e69b Merge pull request #1836 from dmp42/2-fmt
Fmt fixes
2015-09-10 19:07:06 -07:00
Olivier Gambier 9d60bb7c73 Fmt fixes
Signed-off-by: Olivier Gambier <viapanda@gmail.com>
2015-09-10 18:27:13 -07:00
Nathan LeClaire 0fb4991068 Merge pull request #1796 from rikdev/powershell-no-profile
Disabled load PowerShell profile when start the powershell.exe
2015-09-10 15:19:47 -07:00
jclagache ebbc45abea 1434-Added homebrew cask support for VMware Fusion
This aims to lookup for Vmware Fusion required binaries (vmrun and vmware-vdiskmanager) in the system path first before falling back in the default Vmware Fusion installing path.
Thereby, the vmwarefusion docker-machine driver can now be used even if Vmware Fusion is not installed in its default location (with brew cask for example).
Signed-off-by: Jean-Christophe Lagache <jclagache@gmail.com>
2015-09-08 13:39:56 +02:00
Fabio Rapposelli c3ed882b76 Adding FUSE HGFS mount option
Signed-off-by: Fabio Rapposelli <fabio@vmware.com>
2015-09-07 17:31:21 +02:00
Evan Hazlett 3c712ae30a
change debug env var to MACHINE_DEBUG
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-09-05 08:57:03 -04:00
Ivan Ryabchenko d4ce483ebc Disabled load PowerShell profile when start the interpreter powershell.exe
Signed-off-by: Ivan Ryabchenko <rik.ggm@gmail.com>
2015-09-03 02:29:36 +06:00
Evan Hazlett b8f7c3446b Merge pull request #1674 from csakoda/fix-VBox-getRandomIPinSubnet
Fix VirtualBox DHCPServer always uses x.x.x.1, despite getRandomIPinSubnet()
2015-08-28 18:29:01 -04:00
Nathan LeClaire 52dc5734a7 Merge pull request #1735 from praveen12bnitt/1733-virtualbox-network-tuning
added support for configuring nictype and nicpromise mode in virtualbox
2015-08-21 07:51:30 +09:00
Fabio Rapposelli ffe1a7940b [GH-1740] Fix cpu allocation bug
Signed-off-by: Fabio Rapposelli <fabio@vmware.com>
2015-08-20 15:40:06 +02:00