Skip to content

Commit

Permalink
Try adding the mgmt node IP to compute images
Browse files Browse the repository at this point in the history
  • Loading branch information
milliams committed Aug 25, 2023
1 parent 790857c commit 0779128
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions roles/packer/templates/prepare_ansible.sh.j2
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,20 @@ set -euo pipefail

# This script runs on the packer node to set things up, ready to have Ansible connect to it.

sudo dnf install -y glibc-langpack-en.x86_64
sudo localectl set-locale en_GB.utf8
sudo localectl set-keymap gb

{% if ansible_local.citc.csp == "google" %}
sudo yum install -y epel-release
sudo dnf config-manager --set-enabled powertools
{% elif ansible_local.citc.csp == "openstack" %}
sudo yum install -y epel-release
sudo dnf config-manager --set-enabled powertools
# TODO this should point to the eventual fileserver
sudo cat >> /etc/hosts <<EOF
{{ ansible_default_ipv4.address }} mgmt fileserver
EOF
{% elif ansible_local.citc.csp == "aws" %}
sudo yum install -y epel-release
sudo dnf config-manager --set-enabled powertools
Expand Down

0 comments on commit 0779128

Please sign in to comment.