Mercurial > public > ssdt-docker
comparison scripts/backup-container-docker.sh @ 521:8ddeb5a36678 hotfix/2.16.1
add itcm backup conditionals
author | Marc Davis <marc.davis@mcoecn.org> |
---|---|
date | Tue, 30 Jan 2024 10:54:23 -0500 |
parents | 886a7dc796b8 |
children | 579a61f2037d |
comparison
equal
deleted
inserted
replaced
520:3ae0a0fc97e2 | 521:8ddeb5a36678 |
---|---|
45 backupFile=./backup/${entityId}-workflows-db.$(date +%Y-%m-%d-%H-%M-%S).backup | 45 backupFile=./backup/${entityId}-workflows-db.$(date +%Y-%m-%d-%H-%M-%S).backup |
46 echo "entityId is $entityId" | 46 echo "entityId is $entityId" |
47 echo "container name is $containerName" | 47 echo "container name is $containerName" |
48 fi | 48 fi |
49 | 49 |
50 if [[ "$container" = "itcmdb" && -f ".env/itcm-shared.properties" ]]; then | |
51 function prop { | |
52 grep "${1}" .env/itcm-shared.properties|cut -d'=' -f2 | |
53 } | |
54 entityId=$(prop 'entityId' | tr -d '"') | |
55 containerName="$entityId-itcm-db" | |
56 backupFile=./backup/${entityId}-itcm-db.$(date +%Y-%m-%d-%H-%M-%S).backup | |
57 echo "entityId is $entityId" | |
58 echo "container name is $containerName" | |
59 fi | |
60 | |
50 if [ ! -z "$containerName" ]; then | 61 if [ ! -z "$containerName" ]; then |
51 echo "Container is $container" | 62 echo "Container is $container" |
52 if [ "$container" = "invdb" ]; then | 63 if [ "$container" = "invdb" ]; then |
53 echo "IRN is $IRN" | 64 echo "IRN is $IRN" |
54 fi | 65 fi |