Update demo.yml
This commit is contained in:
parent
7e2a5d553c
commit
99db197a39
1 changed files with 7 additions and 8 deletions
15
.github/workflows/demo.yml
vendored
15
.github/workflows/demo.yml
vendored
|
@ -48,14 +48,13 @@ jobs:
|
|||
- name: Wait for new instance running
|
||||
run: |
|
||||
TIMEOUT=$(($(date +%s)+600))
|
||||
while [ $(date +%s) -gt $TIMEOUT ] \
|
||||
do \
|
||||
NEW_INSTANCE_STATE=$(aws lightsail get-instance-state --instance-name ${{ env.OLD_INSTANCE_NAME }} | grep '"name":' | sed 's/ //g' | sed 's/"//g' | sed 's/name://g') \
|
||||
if [ $NEW_INSTANCE_STATE == running ] \
|
||||
then \
|
||||
echo "New instance is running now" \
|
||||
break \
|
||||
fi \
|
||||
while [ $TIMEOUT -gt $(date +%s) ]
|
||||
do
|
||||
NEW_INSTANCE_STATE=$(aws lightsail get-instance-state --instance-name ${{ env.OLD_INSTANCE_NAME }} | grep '"name":' | sed 's/ //g' | sed 's/"//g' | sed 's/name://g')
|
||||
if [ $NEW_INSTANCE_STATE == running ]
|
||||
echo "New instance is running now"
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
- name: Put instance public ports
|
||||
|
|
Loading…
Reference in a new issue