From 0d38224f12cb6329784b28d235217ac675f23a1e Mon Sep 17 00:00:00 2001 From: Jan Stodola Date: Tue, 5 Feb 2019 17:08:10 +0100 Subject: [PATCH] Record date/time of VM creation (cherry picked from commit e918ff807cea5ce53bf8604527477c6fb7d39a2e) --- tests/cli/test_build_and_deploy_azure.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/cli/test_build_and_deploy_azure.sh b/tests/cli/test_build_and_deploy_azure.sh index 56dd75c7..80ce41b8 100755 --- a/tests/cli/test_build_and_deploy_azure.sh +++ b/tests/cli/test_build_and_deploy_azure.sh @@ -97,6 +97,8 @@ rlJournalStart rlRun -t -c "ssh-keygen -t rsa -N '' -f $SSH_KEY_DIR/id_rsa" SSH_PUB_KEY=`cat $SSH_KEY_DIR/id_rsa.pub` + now=$(date -u '+%FT%T') + TMP_DIR=`mktemp -d /tmp/composer-azure.XXXXX` cat > $TMP_DIR/azure-playbook.yaml << __EOF__ --- @@ -117,6 +119,8 @@ rlJournalStart image: name: $OS_IMAGE_NAME resource_group: $AZURE_RESOURCE_GROUP + tags: + "first_seen": "$now" __EOF__ rlRun -t -c "ansible-playbook $TMP_DIR/azure-playbook.yaml"