From 1715a7a87158c8d082653f225cf852c36d172fa7 Mon Sep 17 00:00:00 2001 From: andryyy Date: Fri, 9 Dec 2016 20:52:19 +0100 Subject: [PATCH] Fix messages and rebuild without cache --- build-dovecot.sh | 2 +- build-memcached.sh | 2 +- build-mysql.sh | 2 +- build-nginx.sh | 2 +- build-php-fpm.sh | 2 +- build-postfix.sh | 2 +- build-redis.sh | 2 +- build-rmilter.sh | 4 ++-- build-rspamd.sh | 4 ++-- build-sogo.sh | 4 ++-- 10 files changed, 13 insertions(+), 13 deletions(-) diff --git a/build-dovecot.sh b/build-dovecot.sh index 02113d6a..6363d698 100755 --- a/build-dovecot.sh +++ b/build-dovecot.sh @@ -21,7 +21,7 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi if [[ ! -z "$(docker images -q dovecot)" ]]; then - read -r -p "Found image locally. Rebuild anyway? [y/N] " response + read -r -p "Found image locally. Delete local and rebuild without cache anyway? [y/N] " response response=${response,,} if [[ $response =~ ^(yes|y)$ ]]; then docker rmi dovecot diff --git a/build-memcached.sh b/build-memcached.sh index d8c55d22..84cceb05 100755 --- a/build-memcached.sh +++ b/build-memcached.sh @@ -12,7 +12,7 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi if [[ ! -z "$(docker images -q rmilter)" ]]; then - read -r -p "Found image locally. Rebuild anyway? [y/N] " response + read -r -p "Found image locally. Delete local image and repull? [y/N] " response response=${response,,} if [[ $response =~ ^(yes|y)$ ]]; then docker rmi memcached diff --git a/build-mysql.sh b/build-mysql.sh index 6e9d8d23..b49ded92 100755 --- a/build-mysql.sh +++ b/build-mysql.sh @@ -50,7 +50,7 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi if [[ ! -z "$(docker images -q mysql:${DBVERS})" ]]; then - read -r -p "Found image locally. Rebuild anyway? [y/N] " response + read -r -p "Found image locally. Delete local image and repull? [y/N] " response response=${response,,} if [[ $response =~ ^(yes|y)$ ]]; then docker rmi mysql:${DBVERS} diff --git a/build-nginx.sh b/build-nginx.sh index 6adf677e..5941ce70 100755 --- a/build-nginx.sh +++ b/build-nginx.sh @@ -12,7 +12,7 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi if [[ ! -z "$(docker images -q nginx:${NGINXVERS})" ]]; then - read -r -p "Found image locally. Rebuild/pull anyway? [y/N] " response + read -r -p "Found image locally. Delete local image and repull? [y/N] " response response=${response,,} # tolower if [[ $response =~ ^(yes|y)$ ]]; then docker rmi nginx:${NGINXVERS} diff --git a/build-php-fpm.sh b/build-php-fpm.sh index f546a956..f4a12ac0 100755 --- a/build-php-fpm.sh +++ b/build-php-fpm.sh @@ -11,7 +11,7 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi if [[ ! -z "$(docker images -q php:${PHPVERS})" ]]; then - read -r -p "Found image locally. Rebuild/pull anyway? [y/N] " response + read -r -p "Found image locally. Delete local image and repull? [y/N] " response response=${response,,} if [[ $response =~ ^(yes|y)$ ]]; then docker rmi php:${PHPVERS} diff --git a/build-postfix.sh b/build-postfix.sh index 4ca874ec..89e01f3b 100755 --- a/build-postfix.sh +++ b/build-postfix.sh @@ -21,7 +21,7 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi if [[ ! -z "$(docker images -q postfix)" ]]; then - read -r -p "Found image locally. Rebuild anyway? [y/N] " response + read -r -p "Found image locally. Delete local and rebuild without cache anyway? [y/N] " response response=${response,,} if [[ $response =~ ^(yes|y)$ ]]; then docker rmi postfix diff --git a/build-redis.sh b/build-redis.sh index fcb00a97..6f5e060f 100755 --- a/build-redis.sh +++ b/build-redis.sh @@ -21,7 +21,7 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi if [[ ! -z "$(docker images -q redis:${DBVERS})" ]]; then - read -r -p "Found image locally. Rebuild/pull anyway? [y/N] " response + read -r -p "Found image locally. Delete local image and repull? [y/N] " response response=${response,,} if [[ $response =~ ^(yes|y)$ ]]; then docker rmi redis:${DBVERS} diff --git a/build-rmilter.sh b/build-rmilter.sh index 600b1695..63fa4895 100755 --- a/build-rmilter.sh +++ b/build-rmilter.sh @@ -12,11 +12,11 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi build() { - docker build -t rmilter data/Dockerfiles/rmilter/. + docker build --no-cache -t rmilter data/Dockerfiles/rmilter/. } if [[ ! -z "$(docker images -q rmilter)" ]]; then - read -r -p "Found image locally. Rebuild anyway? [y/N] " response + read -r -p "Found image locally. Delete local and rebuild without cache anyway? [y/N] " response response=${response,,} if [[ $response =~ ^(yes|y)$ ]]; then docker rmi rmilter diff --git a/build-rspamd.sh b/build-rspamd.sh index 4d8d70eb..edee5cf4 100755 --- a/build-rspamd.sh +++ b/build-rspamd.sh @@ -6,7 +6,7 @@ NAME="rspamd-mailcow" build() { - docker build -t rspamd data/Dockerfiles/rspamd/. + docker build --no-cache -t rspamd data/Dockerfiles/rspamd/. } echo "Stopping and removing containers with name tag ${NAME}..." @@ -16,7 +16,7 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi if [[ ! -z "$(docker images -q rspamd)" ]]; then - read -r -p "Found image locally. Rebuild/pull anyway? [y/N] " response + read -r -p "Found image locally. Delete local and rebuild without cache anyway? [y/N] " response response=${response,,} if [[ $response =~ ^(yes|y)$ ]]; then docker rmi rspamd diff --git a/build-sogo.sh b/build-sogo.sh index 91db42bf..b5533ce9 100755 --- a/build-sogo.sh +++ b/build-sogo.sh @@ -12,11 +12,11 @@ if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then fi build() { - docker build -t sogo data/Dockerfiles/sogo/. + docker build --no-cache -t sogo data/Dockerfiles/sogo/. } if [[ ! -z "$(docker images -q sogo)" ]]; then - read -r -p "Found image locally. Rebuild anyway? [y/N] " response + read -r -p "Found image locally. Delete local and rebuild without cache anyway? [y/N] " response response=${response,,} # tolower if [[ $response =~ ^(yes|y)$ ]]; then docker rmi sogo