openstack-ansible-lxc_conta.../releasenotes/notes/container-bind-mounts-1a3a763178255841.yaml
Jesse Pretorius f26d4075e8 Allow container bind mounts to be set in group/host vars
To reduce the number of times a container is restarted during the
build process, this patch implements the facility to consume
LXC bind mounts items from the inventory.

This allows bind mounts to be set in group_vars and therefore have
them applied on container creation instead of later when the service
install playbook runs.

Previously the container_commands option was used, but the bind
mounts are a special case which are better served with its own
set of tasks to ensure that everything needed is in place on the
host and in the container.

Needed-By: Ie2a0528fbd56c8360dd679f55fb2047e0a061c31
Change-Id: I72cdc607d7b4364d78c840bf688e43e013f40709
2016-07-28 14:03:03 +01:00

13 lines
560 B
YAML

---
features:
- The ``lxc-container-create`` role now consumes the variable
``lxc_container_bind_mounts`` which should contain a list
of bind mounts to apply to a newly created container. The
appropriate host and container directory will be created and
the configuration applied to the container config. This
feature is designed to be used in group_vars to ensure that
containers are fully prepared at the time they are created,
thus cutting down the number of times containers are restarted
during deployments and upgrades.