added after_deploy step to travis.yml; updated string generation yet again
This commit is contained in:
parent
4fb55b0c5e
commit
e0208f48ba
|
@ -23,3 +23,7 @@ deploy:
|
|||
on:
|
||||
repo: 10thmagnitude/terraform
|
||||
branch: topic-101-vm-simple-linux
|
||||
|
||||
after_deploy:
|
||||
- provider: script
|
||||
script: terraform destroy
|
||||
|
|
|
@ -4,7 +4,8 @@ set -o errexit -o nounset
|
|||
|
||||
# generate a unique string for CI deployment
|
||||
KEY=$(cat /dev/urandom | tr -cd 'a-z' | head -c 8)
|
||||
KEY+=$(cat /dev/urandom | tr -cd '0-9' | head -c 8)
|
||||
KEY+=$(cat /dev/urandom | tr -cd 'A-Z' | head -c 4)
|
||||
KEY+=$(cat /dev/urandom | tr -cd '0-9' | head -c 4)
|
||||
PASSWORD=KEY+"#"
|
||||
|
||||
terraform get
|
||||
|
@ -21,8 +22,6 @@ terraform apply out.tfplan
|
|||
|
||||
# TODO: determine external validation, possibly Azure CLI
|
||||
|
||||
terraform destroy
|
||||
|
||||
# echo "Setting git user name"
|
||||
# git config user.name $GH_USER_NAME
|
||||
#
|
||||
|
|
Loading…
Reference in New Issue