Commit Graph

54 Commits

Author SHA1 Message Date
Jason Roehm 6789c51b83 Google driver: add `--google-use-internal-ip-only` flag
This addresses previously-closed issue #2876, which points out that
instances created with the `--google-use-internal-ip` command-line flag
are still assigned an external IP address. The new flag (which implies
the presence of `--google-use-internal-ip` if it isn't specified) will
cause the new instance to have no externally-accessible IP address.

Signed-off-by: Jason Roehm <jroehm@gmail.com>
2016-03-01 12:41:19 -05:00
David Gageot 01bd88f6a5 Support creating a machine on an existing google VM
Signed-off-by: David Gageot <david@gageot.net>
2016-01-25 10:34:51 +01:00
David Gageot 52bd740ad3 Revert "Support creating a machine on an existing google VM"
This reverts commit 7cf9ae71be.

Signed-off-by: David Gageot <david@gageot.net>
2016-01-11 15:47:01 +01:00
Daehyeok Mun c33fd0d548 GCE delete instance during rm
Delete instance during rm command regardless instance status

Signed-off-by: Daehyeok Mun <daehyeok@gmail.com>
2016-01-06 18:04:50 -07:00
David Gageot 7cf9ae71be Support creating a machine on an existing google VM
Signed-off-by: David Gageot <david@gageot.net>
2016-01-06 16:55:56 +01:00
David Gageot e143c68cf9 Merge pull request #2732 from dgageot/better-logs
Improve Start/Stop/Kill/Restart lifecycle/logs
2016-01-04 16:24:55 +01:00
David Gageot 9354fed274 Remove some duplication related to swarm
Signed-off-by: David Gageot <david@gageot.net>
2016-01-04 10:40:04 +01:00
David Gageot e9aa75f021 Logs for Restart
Signed-off-by: David Gageot <david@gageot.net>
2016-01-04 10:38:25 +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
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
David Gageot ec76843e03 Cosmetics
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
David Gageot 71f82e86b1 Fix Typo
Signed-off-by: David Gageot <david@gageot.net>
2015-11-19 11:57:36 +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
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
Olivier Gambier 89d9854943 Another pass at linting
Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-11-10 16:58:14 +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
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
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
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
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 bf3cd8b8f4 Remove useless duplication on PreCreateCheck
Signed-off-by: Olivier Gambier <olivier@docker.com>
2015-10-21 13:48:13 -07: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
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
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
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
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
David Gageot 8ce161e830 Support Preemptiple instances on GCE
Signed-off-by: David Gageot <david@gageot.net>
2015-07-18 08:18:35 +02:00
David Gageot e5a7059289 Support static IP on GCE
Signed-off-by: David Gageot <david@gageot.net>
2015-07-18 08:17:50 +02:00
Dave Henderson 3d002187fe Refactoring drivers to embed drivers.DefaultDriver
Signed-off-by: Dave Henderson <dhenderson@gmail.com>
2015-07-07 11:24:00 -04:00
Evan Hazlett f82032b28d remove provider
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-05-21 10:41:03 -04:00
Dave Henderson 3739e4d067 Harmonizing drivers so IPAddress property is kept up-to-date
Signed-off-by: Dave Henderson <Dave.Henderson@ca.ibm.com>
2015-04-30 19:59:23 -04:00
Nathan LeClaire 142ffadc2c Refactor logging to focus on simple STDOUT/STDERR
This also lays the foundation for the possibility of log drivers in the
future, if it is decided that is a direction to pursue.

Signed-off-by: Nathan LeClaire <nathan.leclaire@gmail.com>
2015-04-30 12:04:52 -07:00
zhee 7443980c26 Support "--google-disk-type" flag for google driver
Signed-off-by: Koichi Shiraishi <zcheeee@gmail.com>
2015-04-26 04:38:18 +09:00
Vincent Bernat 91d12d06ec drivers: remove unneeded `GetDockerConfigDir()` and `dockerConfigDir` const
This method is not part of the driver interface anymore.

Signed-off-by: Vincent Bernat <Vincent.Bernat@exoscale.ch>
2015-04-10 17:03:11 +02:00
Guillaume Giamarchi fb1362ea05 Remove dead code
Signed-off-by: Guillaume Giamarchi <guillaume.giamarchi@gmail.com>
2015-03-27 19:25:11 +01:00
Evan Hazlett bc6b66c122
drivers: specify defaults if values are missing; i.e. config updates
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-03-11 22:59:28 -04:00
Evan Hazlett ec91959979
google: updated to new driver interface
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-03-09 23:18:18 -04:00
Evan Hazlett 0b4d58d554 google: enable specifying an auth token
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-02-27 12:31:03 -05:00
Ray Tsang 64544bd1c0 Add google-scopes option to specify Compute Engine scopes
Signed-off-by: Ray Tsang <saturnism@gmail.com>
2015-02-21 17:21:12 -05:00
Evan Hazlett 3a3ef6f45e add discovery to machine config; show swarm membership
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-02-20 13:07:21 -08:00
Evan Hazlett a949e12b6e store swarm config in driver; vendor Godeps; generate swarm token
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-02-20 13:07:21 -08:00
Evan Hazlett 730f0dc68c google: configure firewall if swarm master
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-02-20 13:07:20 -08:00
Evan Hazlett 87a5b43a93 Merge pull request #505 from saturnism/google-driver-disk-size
Added a Disk Size parameter for Google Compute Engine.
2015-02-10 14:35:34 -05:00
Ray Tsang 56d832dd5c Added a Disk Size parameter for Google Compute Engine.
Signed-off-by: Ray Tsang <saturnism@gmail.com>
2015-02-09 13:04:48 -05:00
Sven Dowideit 5c4ee75f4e Add driver names to a few flag descriptions to make is consistent
Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
2015-02-09 10:18:55 +10:00
Evan Hazlett 57810b298d This adds a method to the Driver: PreCreateCheck. This can be used
where you want to run some prerequisite checks before attempting to
create
the machine.  In the case of EC2, this is a check for an existing
keypair.  This can be used in the other drivers in the future as well.

Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2015-01-26 11:27:12 -05:00