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 <ekultails@gmail.com>
This commit is contained in:
Luke Short 2019-07-29 12:07:59 -04:00
parent 236f4792a5
commit 3b813d845c
3 changed files with 7 additions and 30 deletions

View File

@ -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

View File

@ -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:

View File

@ -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'}`