Merge pull request #20 from coredotbin/healthcheck
Add support for healthcheck
This commit is contained in:
commit
7a6f56ab32
@ -63,6 +63,9 @@ containers:
|
||||
mem_limit: 512m
|
||||
volumes:
|
||||
- "{{ appdata_path }}/unifi:{{ container_config_path }}"
|
||||
depends_on:
|
||||
- service: mongodb
|
||||
condition: service_started
|
||||
include_global_env_vars: true
|
||||
restart: "{{ unless_stopped }}"
|
||||
- service_name: quassel
|
||||
@ -75,4 +78,4 @@ containers:
|
||||
mem_limit: 128m
|
||||
ports:
|
||||
- "4242:4242"
|
||||
```
|
||||
```
|
||||
|
@ -80,7 +80,12 @@ services:
|
||||
{% if container.depends_on is defined %}
|
||||
depends_on:
|
||||
{% for dependent in container.depends_on %}
|
||||
{% if dependent is mapping %}
|
||||
{{ dependent.service}}:
|
||||
condition: {{ dependent.condition }}
|
||||
{% else %}
|
||||
- {{ dependent }}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
{% if container.hostname is defined %}
|
||||
@ -160,8 +165,19 @@ services:
|
||||
- {{ envfile }}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
{% if container.user is defined %}
|
||||
user: {{ container.user }}
|
||||
{% if container.healthcheck is defined %}
|
||||
healthcheck:
|
||||
test: "{{ container.healthcheck.test }}"
|
||||
{% if container.healthcheck.interval is defined %}
|
||||
interval: {{ container.healthcheck.interval }}
|
||||
{% endif %}
|
||||
{% if container.healthcheck.timeout is defined %}
|
||||
timeout: {{ container.healthcheck.timeout }}
|
||||
{% endif %}
|
||||
{% if container.healthcheck.retries is defined %}
|
||||
retries: {{ container.healthcheck.retries }}
|
||||
{% endif %}
|
||||
start_period: {{ container.healthcheck.start_period }}
|
||||
{% endif %}
|
||||
{% if container.restart is defined %}
|
||||
restart: {{ container.restart }}
|
||||
|
Loading…
x
Reference in New Issue
Block a user