Skip to content

Commit

Permalink
adding while loop
Browse files Browse the repository at this point in the history
  • Loading branch information
gzukel committed Mar 26, 2024
1 parent 29621b0 commit 00f7838
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/execute_advanced_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,9 @@ jobs:
echo "Monitoring Orchestrator container with ID: $container_id"
while true; do
echo "get current status"
current_status=$(docker ps -q | grep $container_id)
current_status=$(docker ps -q | grep $container_id || echo "docker-ps-error")
echo "current status: ${current_status}"
if [ -z "$current_status" ]; then
if [ "$current_status" == "docker-ps-error" ]; then
echo "no current container get logs"
docker logs $container_id || echo "no logs"
echo "-----------------------------------"
Expand Down Expand Up @@ -83,9 +83,9 @@ jobs:
echo "Monitoring Orchestrator container with ID: $container_id"
while true; do
echo "get current status"
current_status=$(docker ps -q | grep $container_id)
current_status=$(docker ps -q | grep $container_id || echo "docker-ps-error")
echo "current status: ${current_status}"
if [ -z "$current_status" ]; then
if [ "$current_status" == "docker-ps-error" ]; then
echo "no current container get logs"
docker logs $container_id || echo "no logs"
echo "-----------------------------------"
Expand Down Expand Up @@ -121,9 +121,9 @@ jobs:
echo "Monitoring Orchestrator container with ID: $container_id"
while true; do
echo "get current status"
current_status=$(docker ps -q | grep $container_id)
current_status=$(docker ps -q | grep $container_id || echo "docker-ps-error")
echo "current status: ${current_status}"
if [ -z "$current_status" ]; then
if [ "$current_status" == "docker-ps-error" ]; then
echo "no current container get logs"
docker logs $container_id || echo "no logs"
echo "-----------------------------------"
Expand Down Expand Up @@ -159,9 +159,9 @@ jobs:
echo "Monitoring Orchestrator container with ID: $container_id"
while true; do
echo "get current status"
current_status=$(docker ps -q | grep $container_id)
current_status=$(docker ps -q | grep $container_id || echo "docker-ps-error")
echo "current status: ${current_status}"
if [ -z "$current_status" ]; then
if [ "$current_status" == "docker-ps-error" ]; then
echo "no current container get logs"
docker logs $container_id || echo "no logs"
echo "-----------------------------------"
Expand Down

0 comments on commit 00f7838

Please sign in to comment.