Allow to disable Container Healthchecks

A new parameter, ContainerHealthcheckDisabled allows an operator to
disable the container healthcheck when Podman is enabled.

Depends-On: Ic3dd492405b11ec482ff86e1513149c3eceb370f
Change-Id: Id8d7e21d58cf5ab155404db597d96665b94d7c2a
This commit is contained in:
Emilien Macchi 2019-04-12 12:08:31 -04:00
parent ff52c2de67
commit 170cd2be9d
3 changed files with 27 additions and 0 deletions

View File

@ -436,6 +436,7 @@
STARTUP_CONFIG_PATTERN: '/var/lib/tripleo-config/{{ ansible_check_mode | ternary("check-mode/", "") }}container-startup-config-step_*.json'
MOUNT_HOST_PUPPET: '{{docker_puppet_mount_host_puppet | default(true)}}'
CONTAINER_LOG_STDOUT_PATH: "{{ container_log_stdout_path }}"
CONTAINER_HEALTHCHECK_DISABLED: "{{ container_healthcheck_disabled }}"
when: step == "1"
changed_when: false
check_mode: no
@ -494,6 +495,7 @@
paunch {% if enable_debug|bool %}--debug{% else %}-v{% endif %} apply
--default-runtime "{{ container_cli }}"
--container-log-path "{{ container_log_stdout_path }}"
{% if container_healthcheck_disabled|bool and container_cli == 'podman' %}--healthcheck-disabled{% endif %}
--file /var/lib/tripleo-config/hashed-container-startup-config-step_{{ step }}.json
--config-id tripleo_step{{ step }} --managed-by tripleo-{{ tripleo_role_name }}
changed_when: false

View File

@ -94,6 +94,10 @@ parameters:
type: string
description: Absolute path for container stdout output (Podman only)
default: /var/log/containers/stdouts
ContainerHealthcheckDisabled:
type: boolean
description: Whether or not we disable the container healthcheck.
default: false
SELinuxMode:
default: 'enforcing'
description: Configures SELinux mode
@ -246,6 +250,7 @@ outputs:
ENABLE_PUPPET: {get_param: EnablePuppet}
CONTAINER_CLI: {get_param: ContainerCli}
CONTAINER_LOG_STDOUT_PATH: {get_param: ContainerLogStdoutPath}
CONTAINER_HEALTHCHECK_DISABLED: {get_param: ContainerHealthcheckDisabled}
DOCKER_PUPPET_DEBUG: {get_param: DockerPuppetDebug}
DOCKER_PUPPET_PROCESS_COUNT: {get_param: DockerPuppetProcessCount}
DOCKER_PUPPET_MOUNT_HOST_PUPPET: {get_param: DockerPuppetMountHostPuppet}
@ -303,6 +308,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -346,6 +352,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -373,6 +380,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -398,6 +406,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -423,6 +432,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -465,6 +475,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -489,6 +500,7 @@ outputs:
DEPLOY_TARGET_HOST: {get_param: deployment_target_hosts}
CONTAINER_CLI: {get_param: ContainerCli}
CONTAINER_LOG_STDOUT_PATH: {get_param: ContainerLogStdoutPath}
CONTAINER_HEALTHCHECK_DISABLED: {get_param: ContainerHealthcheckDisabled}
DEPLOY_IDENTIFIER: {get_param: DeployIdentifier}
BOOTSTRAP_SERVER_ID: {get_attr: [BootstrapServerId, value]}
ENABLE_DEBUG: {get_param: ConfigDebug}
@ -521,6 +533,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -652,6 +665,7 @@ outputs:
DEPLOY_TARGET_HOST: {get_param: deployment_target_hosts}
CONTAINER_CLI: {get_param: ContainerCli}
CONTAINER_LOG_STDOUT_PATH: {get_param: ContainerLogStdoutPath}
CONTAINER_HEALTHCHECK_DISABLED: {get_param: ContainerHealthcheckDisabled}
DEPLOY_IDENTIFIER: {get_param: DeployIdentifier}
BOOTSTRAP_SERVER_ID: {get_attr: [BootstrapServerId, value]}
ENABLE_DEBUG: {get_param: ConfigDebug}
@ -672,6 +686,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -690,6 +705,7 @@ outputs:
DEPLOY_TARGET_HOST: {get_param: deployment_target_hosts}
CONTAINER_CLI: {get_param: ContainerCli}
CONTAINER_LOG_STDOUT_PATH: {get_param: ContainerLogStdoutPath}
CONTAINER_HEALTHCHECK_DISABLED: {get_param: ContainerHealthcheckDisabled}
DEPLOY_IDENTIFIER: {get_param: DeployIdentifier}
BOOTSTRAP_SERVER_ID: {get_attr: [BootstrapServerId, value]}
ENABLE_DEBUG: {get_param: ConfigDebug}
@ -710,6 +726,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -730,6 +747,7 @@ outputs:
DOCKER_PUPPET_MOUNT_HOST_PUPPET: {get_param: DockerPuppetMountHostPuppet}
CONTAINER_CLI: {get_param: ContainerCli}
CONTAINER_LOG_STDOUT_PATH: {get_param: ContainerLogStdoutPath}
CONTAINER_HEALTHCHECK_DISABLED: {get_param: ContainerHealthcheckDisabled}
template: |
- hosts: DEPLOY_SOURCE_HOST
name: Gather facts from undercloud
@ -764,6 +782,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET
@ -791,6 +810,7 @@ outputs:
enable_puppet: ENABLE_PUPPET
container_cli: CONTAINER_CLI
container_log_stdout_path: CONTAINER_LOG_STDOUT_PATH
container_healthcheck_disabled: CONTAINER_HEALTHCHECK_DISABLED
docker_puppet_debug: DOCKER_PUPPET_DEBUG
docker_puppet_process_count: DOCKER_PUPPET_PROCESS_COUNT
docker_puppet_mount_host_puppet: DOCKER_PUPPET_MOUNT_HOST_PUPPET

View File

@ -0,0 +1,5 @@
---
features:
- |
ContainerHealthcheckDisabled is a new parameter which allows to disable
the container healthcheck management in Paunch.