Skip to content
Snippets Groups Projects
build-ansible-hosts.sh 285 B
Newer Older
Nathan Rodet's avatar
Nathan Rodet committed
#!/bin/bash

# Create hosts.yaml file with base configuration
echo "instances:
  hosts:" > ./hosts.yaml

# Add host url for each instance
for ((i=0; i<=$INSTANCE_COUNT; i++)); do
    echo "    ${ENVIRONMENT}-${i}.cma.alpha.grandlyon.com:" >> ./hardening-scripts/ansible/hosts.yaml
done