Skip to content

armgit / core

Public Imported from GitHub
0

100% open-source IoT Platform - Integrate your devices, add intelligence, build custom apps

CI/CD: Minor

Rich Turnerf210775c5850
diff --git a/.ci_cd/aws/login.sh b/.ci_cd/aws/login.sh
index b5ba732e6..60e44eb35 100644
--- a/.ci_cd/aws/login.sh
+++ b/.ci_cd/aws/login.sh
@@ -31,7 +31,7 @@ AWS_PROFILE=github
export AWS_PROFILE=$AWS_PROFILE
echo "Validating AWS credentials"
-aws sts get-caller-identity 1>/dev/null 2>/dev/null
+aws sts get-caller-identity
if [ $? -ne 0 ]; then
echo "Failed to login to AWS"
diff --git a/.ci_cd/deploy.sh b/.ci_cd/deploy.sh
index f7f00f5e3..7c5d63798 100644
--- a/.ci_cd/deploy.sh
+++ b/.ci_cd/deploy.sh
@@ -229,12 +229,15 @@ if [ \$? -ne 0 ]; then
fi
# Attempt docker compose down
-echo "Stopping existing stack"
-docker-compose -f temp/docker-compose.yml -p or down 2> /dev/null
+CONTAINER_IDS=$(docker ps -q)
+if [ -n "$CONTAINER_IDS" ]; then
+ echo "Stopping existing stack"
+ docker-compose -f temp/docker-compose.yml -p or down 2> /dev/null
-if [ \$? -ne 0 ]; then
- echo "Deployment failed to stop the existing stack"
- exit 1
+ if [ \$? -ne 0 ]; then
+ echo "Deployment failed to stop the existing stack"
+ exit 1
+ fi
fi
# Run host init