bootstrap-vz/bootstrapvz/providers/gce
Paul Marks 15c7d1ccb3 Do not remove ::1 from the loopback interface.
An environment with AF_INET6 sockets but no loopback interface creates
nothing but pain.

If an IPv4 server binds to 0.0.0.0:8080, clients may connect to
0.0.0.0:8080, which automatically picks 127.0.0.1 as a source address.
However, when a server binds to [::]:8080, the absence of ::1 causes
clients to fail with ENETUNREACH.

For a demonstration, run the following in a python shell:

import socket
s = socket.socket(socket.AF_INET6, socket.SOCK_STREAM, 0)
s.bind(("", 0))
print s.getsockname()  # Example: ('::', 39079, 0, 0)
s.listen(10)
c = socket.socket(socket.AF_INET6, socket.SOCK_STREAM, 0)
c.connect(s.getsockname())
print c.getsockname(), c.getpeername()

This yields the following error:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.7/socket.py", line 224, in meth
    return getattr(self._sock,name)(*args)
socket.error: [Errno 101] Network is unreachable
2016-03-24 17:14:17 -07:00
..
assets/initramfs-tools/scripts/local-premount Fix a problem with Debian 8 on GCE with >2TB disks 2015-09-23 16:55:16 -07:00
tasks Do not remove ::1 from the loopback interface. 2016-03-24 17:14:17 -07:00
__init__.py Again fix the expand-root script for GCE. The volume is not /dev/loop0 2016-03-03 13:59:01 -08:00
manifest-schema.yml Remove image section in manifest 2015-12-13 19:41:18 +01:00
README.rst fix document toctree 2016-03-15 11:13:05 +09:00

Google Compute Engine
=====================

The `GCE <https://cloud.google.com/products/compute-engine/>`__ provider
can creates image as expected by GCE - i.e. raw disk image in \*.tar.gz
file. It can upload created images to Google Storage Engine (to URI
provided in manifest by ``gcs_destination``) and can register image to
be used by Google Compute Engine to project provided in manifest by
``gce_project``. Both of those functionalities are not fully tested yet.

Manifest settings
-----------------

Provider
~~~~~~~~

-  ``description``: Description of the image.
-  ``gcs_destination``: Image destination in GSE.
-  ``gce_project``: GCE project in which to register the image.


Example:

.. code-block:: yaml

    ---
    provider:
      name: gce
      description: Debian {system.release} {system.architecture}
      gcs_destination: gs://my-bucket
      gce_project: my-project