Skip to content

Commit

Permalink
handled agent kill in post upgrade stage (#2818)
Browse files Browse the repository at this point in the history
  • Loading branch information
tanmaygarg-oracle committed Jun 18, 2024
1 parent 4032861 commit a8f47ae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions OracleIdentityGovernance/samples/scripts/agentManagement.sh
Original file line number Diff line number Diff line change
Expand Up @@ -740,7 +740,7 @@ kill()
if [ "$containerRuntime" = "docker" ] && [ "$(docker ps -a -f "name=$AI" --format '{{.Names}}')" ]
then

if [ ! "$operation" = "upgrade" ]
if [ ! "$operation" = "upgrade" ] && [ ! "$operation" = "postUpgrade" ]
then
docker exec "$AI" /bin/bash -c "agent --config /app/data/conf/config.json ido lcm -i graceful_shutdown;"
echo "INFO: Waiting for running operations to complete. It may take some time"
Expand All @@ -749,7 +749,7 @@ kill()
docker rm -f "$AI"
elif [ "$containerRuntime" = "podman" ] && [ "$(podman ps -a -f "name=$AI" --format '{{.Names}}')" ]
then
if [ ! "$operation" = "upgrade" ]
if [ ! "$operation" = "upgrade" ] && [ ! "$operation" = "postUpgrade" ]
then
podman exec "$AI" /bin/bash -c "agent --config /app/data/conf/config.json ido lcm -i graceful_shutdown;"
echo "INFO: Waiting for running operations to complete. It may take some time"
Expand Down

0 comments on commit a8f47ae

Please sign in to comment.