b0be2e9327
In Ansible 2.3, 'ansible_user' seems to be undefined unless set within the inventory for a host. 'ansible_user_id' contains the current user running Ansible, but is only set after facts are gathered. Change-Id: Id5b76a87809f03951c954fc3d752419a673403f7
27 lines
899 B
YAML
27 lines
899 B
YAML
---
|
|
# Copyright 2016, Rackspace US, Inc.
|
|
#
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
# you may not use this file except in compliance with the License.
|
|
# You may obtain a copy of the License at
|
|
#
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
#
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
# See the License for the specific language governing permissions and
|
|
# limitations under the License.
|
|
|
|
- name: Execute the openstack-host role
|
|
hosts: localhost
|
|
connection: local
|
|
become: true
|
|
gather_facts: true
|
|
pre_tasks:
|
|
- include: "common-tasks/test-force-package-cache-update.yml"
|
|
roles:
|
|
- role: "{{ openstack_hosts_rolename | default('openstack_hosts') }}"
|
|
vars_files:
|
|
- test-vars.yml
|