Ensure lxc_hosts have updated facts before container creation
This change adds a quick fact gather on lxc_hosts prior to creating the containers. This was added because lxc-container-create will fail should the facts be missing or stale. Change-Id: Ie2b2dd35d64df76d214991c17d30d7af6455ee2a Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
This commit is contained in:
parent
6e64a24085
commit
31a2c9da0e
@ -13,6 +13,10 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
|
- name: Gather lxc container host facts
|
||||||
|
hosts: "{{ lxc_host_group | default('lxc_hosts')}}"
|
||||||
|
gather_facts: "{{ gather_facts | default(True) }}"
|
||||||
|
|
||||||
- name: Create container(s)
|
- name: Create container(s)
|
||||||
hosts: "{{ container_group|default('all_containers') }}"
|
hosts: "{{ container_group|default('all_containers') }}"
|
||||||
gather_facts: false
|
gather_facts: false
|
||||||
|
Loading…
Reference in New Issue
Block a user