If the state dir is preserved then the VM should come up with the same mac
address on subsequent reboots.
Fixes regression in #2498.
Rather than fixing the typo in the associated comments just remove them since
they don't really convey any useful information.
Signed-off-by: Ian Campbell <ijc@docker.com>
This PR is used to fix the issue #2488.
Currently we use '-net' the old way to initialize a host nic
interface, this method will not work on arm64 platform(#2488 issue),
so we use the '-netdev' method which will work on both arm64 and amd64.
Signed-off-by: Dennis Chen <dennis.chen@arm.com>
This adds support for the updated Hyperkit API, which is needed to
request a specific IP address in new versions of VPNKit / Docker for
Mac. IPs encoded in the UUID (the old method) will now be ignored by
VPNKit.
A preferred IPv4 address can be requested directly via the new API. The
IP is then associated with the VPNKit UUID identifying the connection.
The UUID is either user specified or randomly assigned if left empty.
VMs launched with the same VPNKit UUID it will get the same IP address.
To avoid having to copy the assigned UUID manually, a file `uuid.vpnkit`
is now saved in the state directory when the UUID is generated. The UUID
from this file is reused automatically if it exists, unless a different
VPNKit UUID is specified on the command line. This also means that VMs
that use dynamically assigned IPs will by default get the same IP each
time they are started, as long as the state directory exists.
This change is incompatible with earlier versions of VPNKit / Hyperkit
and a recent version of Docker for Mac has to be installed. If the
feature is unsupported using the `--ip` parameter will exit with an
error message.
Signed-off-by: Magnus Skjegstad <magnus@skjegstad.com>
Tested with:
- boot from kernel + initrd with metadata (appears as sr0)
- boot from iso with no metadata (root is sr0)
- boot from iso with metadata (root is sr0, metadata is sr1)
- boot from iso with metadata using containerized qemu
In all cases where it was present the metadata was correctly expanded to
/var/config.
Signed-off-by: Ian Campbell <ijc@docker.com>
The local changes were merged, so switching back to the original
repository. A minor change in API was needed.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Currently we depend on the qemu to detect the firmware file format
automatically, which is dangerous. This patch specify the 'raw'
format explicitly to remove the kind of restrictions.
Signed-off-by: Dennis Chen <dennis.chen@arm.com>
This add a -device option which enables the re-use of an existing
device. The device state is update to use a potentially new base-url
ro PXE boot from. This maybe faster than provisioning a new server.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Adds a new option, '-keep' which will keep the machine around,
but by default remove the machine when done.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
The -serve command starts a local HTTP server which serves
the kernel and initrd files. The server can then easily be
made available via ngrok or other means.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
When an AWS machine is stopped and there is no console output the CLI
panics due to a nil pointer dereference. This commit checks that the
console output is not null before attempting to decode it.
Signed-off-by: Dave Tucker <dt@docker.com>
Instances were being created in a different AZ to the one specified in
the zone variable. This could lead to situations where the disks and the
instance were in different AZs and would result in an error.
This commit adds placement information to the API call used to create
the instance.
Fixes: #2388
Signed-off-by: Dave Tucker <dt@docker.com>
The iPXE needs the hard coded value of 'kernel-params' but
we should append the kernel command line from the YAML in case
it sets other parameters.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
On 'linuxkit run packet' ssh into the SOS for the newly created
machine. This requires that you have set up your ssh keys and
have at least once logged into the ssh so that the host keys
are present in the 'known_hosts' file.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
This option configures the machine to always PXE boot. By
default it would only PXE boot for the first time.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
If a packet account is shared between users, this makes it
clearer who created the machine.
Also, switch "moby" to "linuxkit"
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
To enable this bump github.com/Azure/go-ansiterm and github.com/docker/docker
to their latest version which have switched to lower case.
This in turn requires bumping golang.org/x/sys since github.com/docker/docker/pkg/term
now uses `unix.IoctlGetTermios`. I picked the revision from docker/docker's vendor.conf.
Signed-off-by: Ian Campbell <ijc@docker.com>
- When executing on aarch64, use it as the default arch
- When selecting aarch64 on a non aarch64 system set the
CPU flag to a default value (not 'host').
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
This commit updates the support for pushing images into OpenStack by
inheriting environment variables for endpoint and authentication
information, when available.
It also attempts to make the `openstack run` support more consistent
with other providers (specifically GCP and AWS), i.e just take the name
of the image as the argument and launch an instance using that.
Finally, it also updates the relevant documentation for OpenStack
support.
Signed-off-by: Nick Jones <nick@dischord.org>
This commit allows the GCP backend to use the familiar `-disk` behaviour
that the local hypervisors use. The `file` attribute is used as the disk
name in GCP. The size is converted to GB and is always > 1GB.
This has the benefit of allowing multiple disks to be used with GCP
instances.
Signed-off-by: Dave Tucker <dt@docker.com>
By default we want qemu to use the EFI firmware image in the qemu
container. However the logic in the code would always bind mount
the FW image into the container.
This commit changes the logic to only bind mount the FW image if
it was specified on the commandline.
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>