Need more coffee.

This commit is contained in:
gospodar 2023-02-10 21:51:28 +01:00
parent 46dc8c171c
commit f5d1d86a3a

12
main.sh
View File

@ -106,7 +106,7 @@ fi
}
function push {
if [ "rsync_push" = true ]
if [ "$rsync_push" = true ]
then
#Push - Dockerized
if [ "push_clean" = true ]
@ -117,9 +117,9 @@ function push {
}
function dockerbackup {
if [ "docker_enabled" = true]
if [ "$docker_enabled" = true]
then
if [ "docker_images" = true]
if [ "$docker_images" = true]
then
echo "Backing up Docker images..." >&2
for i in `docker inspect --format='{{.Name}}' $(docker ps -q) | cut -f2 -d\/`
@ -132,7 +132,7 @@ function dockerbackup {
echo "Finished" >&2
done
fi
if [ "docker_volumes" = true ]
if [ "$docker_volumes" = true ]
then
echo "Backing up Docker volumes..." >&2
for i in `docker inspect --format='{{.Name}}' $(docker ps -q) | cut -f2 -d\/`
@ -148,7 +148,7 @@ function dockerbackup {
echo "Finished" >&2
done
fi
if [ "docker_data" = true ]
if [ "$docker_data" = true ]
then
echo "Backing up container information..." >&2
for i in `docker inspect --format='{{.Name}}' $(docker ps -q) | cut -f2 -d\/`
@ -164,7 +164,7 @@ function dockerbackup {
}
function runbackup {
if [ "enabled" = true ]
if [ "$enabled" = true ]
then
# step 1 : create directory
makedir