From 3b813d845cba18977afea00ca62ea6e6d6d5ba45 Mon Sep 17 00:00:00 2001 From: Luke Short Date: Mon, 29 Jul 2019 12:07:59 -0400 Subject: [PATCH] Move the Hiera symlink task from post configuration to deployment steps. This helps to consolidate the Undercloud and Standalone deployments. It also avoids an issue where the Ansible Python interperter cannot be found. Change-Id: I01a95be975011d2419a523da572503e0ebcfa49b Resolves: rhbz#1733608 Signed-off-by: Luke Short --- common/deploy-steps.j2 | 7 +++++ extraconfig/post_deploy/standalone_post.yaml | 28 -------------------- extraconfig/post_deploy/undercloud_post.sh | 2 -- 3 files changed, 7 insertions(+), 30 deletions(-) diff --git a/common/deploy-steps.j2 b/common/deploy-steps.j2 index fa85661681..5b76b45294 100644 --- a/common/deploy-steps.j2 +++ b/common/deploy-steps.j2 @@ -508,7 +508,14 @@ outputs: hieradata_variable_end_string: $$ hieradata_files: "{{ '{{' }} lookup('file', '{{role.name}}/deployment-hierarchy.yaml') {{ '}}' }}" when: tripleo_role_name == '{{role.name}}' + {%- endfor %} + - name: Hiera symlink + file: + src: /etc/puppet/hiera.yaml + dest: /etc/hiera.yaml + state: link + force: true tags: - overcloud - pre_deploy_steps diff --git a/extraconfig/post_deploy/standalone_post.yaml b/extraconfig/post_deploy/standalone_post.yaml index 2a5b6278b7..d1037abf03 100644 --- a/extraconfig/post_deploy/standalone_post.yaml +++ b/extraconfig/post_deploy/standalone_post.yaml @@ -37,34 +37,6 @@ parameters: resources: - StandalonePostConfig: - type: OS::Heat::SoftwareConfig - properties: - group: ansible - inputs: - - name: ansible_python_interpreter - description: Python interpreter to use for the ansible execution - default: {get_param: PythonInterpreter} - config: | - --- - - name: StandalonePostConfig - connection: local - hosts: localhost - tasks: - - name: Hiera symlink - file: - src: /etc/puppet/hiera.yaml - dest: /etc/hiera.yaml - state: link - force: yes - - StandalonePostDeployment: - type: OS::Heat::SoftwareDeploymentGroup - properties: - name: StandalonePostDeployment - servers: {get_param: servers} - config: {get_resource: StandalonePostConfig} - CloudsYamlConfig: type: OS::Heat::SoftwareConfig properties: diff --git a/extraconfig/post_deploy/undercloud_post.sh b/extraconfig/post_deploy/undercloud_post.sh index f5a3954561..ed391ec19b 100755 --- a/extraconfig/post_deploy/undercloud_post.sh +++ b/extraconfig/post_deploy/undercloud_post.sh @@ -1,8 +1,6 @@ #!/bin/bash set -eux -ln -sf /etc/puppet/hiera.yaml /etc/hiera.yaml - HOMEDIR="$homedir" USERNAME=`ls -ld $HOMEDIR | awk {'print $3'}` GROUPNAME=`ls -ld $HOMEDIR | awk {'print $4'}`