VMX is in FeatureNames, but SVM is in ExtraFeatureNames
This meant that detection *always* failed for SVM (AMD)
Thanks to user @hilbertxia
Signed-off-by: Anders F Björklund <anders.f.bjorklund@gmail.com>
This commit ensures that when a plugin instance is closed the goroutines
responsible for streaming stdout and stderr of the called binary will
also exit, preventing a goroutines leak.
Before this commit these goroutines could stay blocked forever if
Close() was called while the binary still had some pending output.
I found this bug after debugging a real world goroutine leak, the
goroutines dump would show thousands of goroutines at:
```
github.com/tsuru/tsuru/vendor/github.com/docker/machine/libmachine/drivers/plugin/localbinary.stream(0xc023013d80, 0xc0000aad20)
/home/travis/gopath/src/github.com/tsuru/tsuru/vendor/github.com/docker/machine/libmachine/drivers/plugin/localbinary/plugin.go:177 +0x7c
created by github.com/tsuru/tsuru/vendor/github.com/docker/machine/libmachine/drivers/plugin/localbinary.(*Plugin).AttachStream
/home/travis/gopath/src/github.com/tsuru/tsuru/vendor/github.com/docker/machine/libmachine/drivers/plugin/localbinary/plugin.go:183 +0x67
```
Signed-off-by: Cezar Sa Espinola <cezarsa@gmail.com>
- Only name for all SUSE family is used
- Prevent to rewrite `/usr/sbin/docker-runc` provided by modern `docker-runc` package with broken link.
Signed-off-by: Konstantin Malanchev <hombit@gmail.com>
filter to search for a subnet searches by both regionZone and VpcId,
but when no matches were found, the error message neglected to mention
that the VPC ID was part of the search criteria
Signed-off-by: F. Eugene Aumson <feuGeneA@github.com>
Without this change,
docker-machine create \
--driver amazonec2 \
--amazonec2-security-group parity-security-group \
--amazonec2-instance-type t2.medium \
--amazonec2-access-key ... \
--amazonec2-secret-key ... \
--amazonec2-root-size 128 \
parity-node
yields the program output
Error with pre-create check: "unable to find a subnet in the zone: us-e
ast-1a"
which comes from drivers/amazonec2/amazonec2.go:506.
But that message is misleading. After sprinkling in some
`fmt.Println`s, I discovered that the missing piece of info is not
actually the subnet, but rather the VPC ID, which is "none".
With this change, that same command now yields:
Error setting machine configuration from flags provided: amazonec2 driv
er requires either the --amazonec2-subnet-id or --amazonec2-vpc-id opti
on or an AWS Account with a default vpc-id
Signed-off-by: F. Eugene Aumson <feuGeneA@github.com>
Add the --google-service-account flag to create VMs that are not
provisioned with the default service account.
Signed-off-by: Peter Schultz <peter.schultz@classmarkets.com>
If the shell command looks like
"condition1 && command1 || condition2 && command2 || command3"
then condition2 will never be checked if condition1 is true and command1
exists normally. In order for this code to run expectedly, it should look
like
"(condition1 && command1) || (condition2 && command2) || command3"
instead.
Specifically, with the code like
"[ ! -d /Users ]&& sudo mkdir /Users; sudo mount --bind /mnt/hgfs/Users /Users || [ -f /usr/local/bin/vmhgfs-fuse ]&& sudo /usr/local/bin/vmhgfs-fuse -o allow_other .host:/Users /Users || sudo mount -t vmhgfs -o uid=$(id -u),gid=$(id -g) .host:/Users /Users"
if both "[ ! -d /Users ]" and "sudo mkdir /Users; sudo mount --bind
/mnt/hgfs/Users /Users" are true, then the existence of a file
/usr/local/bin/vmhgfs-fuse will never be examined and always be executed
even if the file doesn't exist. Consequently, it always fails.
Signed-off-by: Motonori Shindo <motonori@shin.do>