Uploaded images to Docker hub

This commit is contained in:
andryyy
2016-12-13 22:12:54 +01:00
parent 1910e3bc29
commit 94530fcecd
6 changed files with 5 additions and 105 deletions

View File

@@ -10,32 +10,12 @@ if [[ ! ${PDNS_IP} =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
exit 1
fi
build() {
docker build --no-cache -t postfix data/Dockerfiles/postfix/.
}
if [[ ${1} == "--reconf" ]]; then
reconf
exit 0
fi
echo "Stopping and removing containers with name tag ${NAME}..."
if [[ ! -z $(docker ps -af "name=${NAME}" -q) ]]; then
docker stop $(docker ps -af "name=${NAME}" -q)
docker rm $(docker ps -af "name=${NAME}" -q)
fi
if [[ ! -z "$(docker images -q postfix)" ]]; then
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
build
fi
else
build
fi
sed -i "/^user/c\user = ${DBUSER}" data/conf/postfix/sql/*
sed -i "/^password/c\password = ${DBPASS}" data/conf/postfix/sql/*
sed -i "/^dbname/c\dbname = ${DBNAME}" data/conf/postfix/sql/*
@@ -52,4 +32,4 @@ docker run \
--network=${DOCKER_NETWORK} \
--network-alias postfix \
-h ${MAILCOW_HOSTNAME} \
-d postfix
-d andryyy/mailcow-dockerized:postfix