Merge branch 'blacklist'

This commit is contained in:
Tyler Pace
2023-04-18 18:21:46 -07:00
2 changed files with 3 additions and 1 deletions
+2
View File
@@ -37,6 +37,8 @@ b) Set ENV `AUTOHEAL_CONTAINER_LABEL=all` to watch all running containers.
c) Set ENV `AUTOHEAL_CONTAINER_LABEL` to existing label name that has the value `true`.
Note: You can also exclude a container (eg. if using `AUTOHEAL_CONTAINER_LABEL=all`) by setting the label `autoheal=false`.
Note: You must apply `HEALTHCHECK` to your docker images first. See https://docs.docker.com/engine/reference/builder/#healthcheck for details.
Use `tcp://` for unencrypted tcp and `tcps://` for TLS enabled connection.
See https://docs.docker.com/engine/security/https/ for how to configure TCP with mTLS.
+1 -1
View File
@@ -123,7 +123,7 @@ then
do
STOP_TIMEOUT=".Labels[\"autoheal.stop.timeout\"] // $AUTOHEAL_DEFAULT_STOP_TIMEOUT"
get_container_info | \
jq -r "foreach .[] as \$CONTAINER([];[]; \$CONTAINER | .Id, .Names[0], .State, ${STOP_TIMEOUT})" | \
jq -r ".[] | select(.Labels[\"autoheal\"] != \"False\") | foreach . as \$CONTAINER([];[]; \$CONTAINER | .Id, .Names[0], .State, ${STOP_TIMEOUT})" | \
while read -r CONTAINER_ID && read -r CONTAINER_NAME && read -r CONTAINER_STATE && read -r TIMEOUT
do
# shellcheck disable=2039