Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 15 additions & 10 deletions tests/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,21 @@ export PATH="$(pwd)/tectonic-dev/installer:${PATH}"
cd tectonic-dev

echo -e "\\e[36m Creating Tectonic configuration...\\e[0m"
CONFIG=$(python -c 'import sys, yaml, json; json.dump(yaml.load(sys.stdin), sys.stdout)' < examples/tectonic.aws.yaml)
CONFIG=$(echo "${CONFIG}" | jq ".name = \"${CLUSTER_NAME}\"" |\
jq ".baseDomain = \"${DOMAIN}\"" |\
jq ".licensePath = \"${LICENSE_PATH}\"" |\
jq ".pullSecretPath = \"${PULL_SECRET_PATH}\"" |\
jq ".aws.region = \"${AWS_REGION}\"" |\
jq ".aws.master.iamRoleName = \"tf-tectonic-master-node\"" |\
jq ".aws.worker.iamRoleName = \"tf-tectonic-worker-node\""
)
echo "${CONFIG}" | python -c 'import sys, yaml, json; yaml.safe_dump(json.load(sys.stdin), sys.stdout)' > "${CLUSTER_NAME}.yaml"
python <<-EOF >"${CLUSTER_NAME}.yaml"
import sys
import yaml

with open('examples/tectonic.aws.yaml') as f:
config = yaml.load(f)
config['name'] = '${CLUSTER_NAME}'
config['baseDomain'] = '${DOMAIN}'
config['licensePath'] = '${LICENSE_PATH}'
config['pullSecretPath'] = '${PULL_SECRET_PATH}'
config['aws']['region'] = '${AWS_REGION}'
config['aws']['master']['iamRoleName'] = 'tf-tectonic-master-node'
config['aws']['worker']['iamRoleName'] = 'tf-tectonic-worker-node'
yaml.safe_dump(config, sys.stdout)
EOF

echo -e "\\e[36m Initializing Tectonic...\\e[0m"
tectonic init --config="${CLUSTER_NAME}".yaml
Expand Down