|
@ -20,6 +20,7 @@ docker_deploy() { |
|
|
_cfullchain="$5" |
|
|
_cfullchain="$5" |
|
|
_debug _cdomain "$_cdomain" |
|
|
_debug _cdomain "$_cdomain" |
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_LABEL |
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_LABEL |
|
|
|
|
|
_debug2 DEPLOY_DOCKER_CONTAINER_LABEL "$DEPLOY_DOCKER_CONTAINER_LABEL" |
|
|
if [ -z "$DEPLOY_DOCKER_CONTAINER_LABEL" ]; then |
|
|
if [ -z "$DEPLOY_DOCKER_CONTAINER_LABEL" ]; then |
|
|
_err "The DEPLOY_DOCKER_CONTAINER_LABEL variable is not defined, we use this label to find the container." |
|
|
_err "The DEPLOY_DOCKER_CONTAINER_LABEL variable is not defined, we use this label to find the container." |
|
|
_err "See: $_DEPLOY_DOCKER_WIKI" |
|
|
_err "See: $_DEPLOY_DOCKER_WIKI" |
|
@ -64,26 +65,31 @@ docker_deploy() { |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_KEY_FILE |
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_KEY_FILE |
|
|
|
|
|
_debug2 DEPLOY_DOCKER_CONTAINER_KEY_FILE "$DEPLOY_DOCKER_CONTAINER_KEY_FILE" |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_KEY_FILE" ]; then |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_KEY_FILE" ]; then |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_KEY_FILE "$DEPLOY_DOCKER_CONTAINER_KEY_FILE" |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_KEY_FILE "$DEPLOY_DOCKER_CONTAINER_KEY_FILE" |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_CERT_FILE |
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_CERT_FILE |
|
|
|
|
|
_debug2 DEPLOY_DOCKER_CONTAINER_CERT_FILE "$DEPLOY_DOCKER_CONTAINER_CERT_FILE" |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_CERT_FILE" ]; then |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_CERT_FILE" ]; then |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_CERT_FILE "$DEPLOY_DOCKER_CONTAINER_CERT_FILE" |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_CERT_FILE "$DEPLOY_DOCKER_CONTAINER_CERT_FILE" |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_CA_FILE |
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_CA_FILE |
|
|
|
|
|
_debug2 DEPLOY_DOCKER_CONTAINER_CA_FILE "$DEPLOY_DOCKER_CONTAINER_CA_FILE" |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_CA_FILE" ]; then |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_CA_FILE" ]; then |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_CA_FILE "$DEPLOY_DOCKER_CONTAINER_CA_FILE" |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_CA_FILE "$DEPLOY_DOCKER_CONTAINER_CA_FILE" |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE |
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE |
|
|
|
|
|
_debug2 DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE "$DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE" |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE" ]; then |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE" ]; then |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE "$DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE" |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE "$DEPLOY_DOCKER_CONTAINER_FULLCHAIN_FILE" |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_RELOAD_CMD |
|
|
_getdeployconf DEPLOY_DOCKER_CONTAINER_RELOAD_CMD |
|
|
|
|
|
_debug2 DEPLOY_DOCKER_CONTAINER_RELOAD_CMD "$DEPLOY_DOCKER_CONTAINER_RELOAD_CMD" |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_RELOAD_CMD" ]; then |
|
|
if [ "$DEPLOY_DOCKER_CONTAINER_RELOAD_CMD" ]; then |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_RELOAD_CMD "$DEPLOY_DOCKER_CONTAINER_RELOAD_CMD" |
|
|
_savedeployconf DEPLOY_DOCKER_CONTAINER_RELOAD_CMD "$DEPLOY_DOCKER_CONTAINER_RELOAD_CMD" |
|
|
fi |
|
|
fi |
|
@ -188,6 +194,7 @@ _docker_cp() { |
|
|
_to="$3" |
|
|
_to="$3" |
|
|
_info "Copying file from $_from to $_to" |
|
|
_info "Copying file from $_from to $_to" |
|
|
_dir="$(dirname "$_to")" |
|
|
_dir="$(dirname "$_to")" |
|
|
|
|
|
_debug2 _dir "$_dir" |
|
|
_docker_exec "$_dcid" mkdir -p "$_dir" |
|
|
_docker_exec "$_dcid" mkdir -p "$_dir" |
|
|
if [ "$_USE_DOCKER_COMMAND" ]; then |
|
|
if [ "$_USE_DOCKER_COMMAND" ]; then |
|
|
if [ "$DEBUG" ] && [ "$DEBUG" -ge "2" ]; then |
|
|
if [ "$DEBUG" ] && [ "$DEBUG" -ge "2" ]; then |
|
|