mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-29 15:06:26 +02:00
Finished docker refactoring
This commit is contained in:
@@ -6,7 +6,7 @@ services:
|
||||
{% endif %}
|
||||
{# Load Redis #}
|
||||
{% if applications[application_id].docker.redis.enabled | default(false) | bool %}
|
||||
{% include 'templates/docker/services/redis.yml.j2' %}
|
||||
{% include 'roles/docker-redis/templates/service.yml.j2' %}
|
||||
{% endif %}
|
||||
{# Load OAuth2 Proxy #}
|
||||
{% if not applications | is_feature_enabled('oauth2',application_id) %}
|
||||
|
19
roles/docker-compose/templates/networks.yml.j2
Normal file
19
roles/docker-compose/templates/networks.yml.j2
Normal file
@@ -0,0 +1,19 @@
|
||||
{# This template needs to be included in docker-compose.yml #}
|
||||
networks:
|
||||
{% if applications | is_feature_enabled('central_database',application_id) and database_type is defined %}
|
||||
central_{{ database_type }}:
|
||||
external: true
|
||||
{% endif %}
|
||||
{% if applications[application_id].get('features', {}).get('ldap', false) and applications.ldap.network.docker | bool %}
|
||||
central_ldap:
|
||||
external: true
|
||||
{% endif %}
|
||||
default:
|
||||
{% if application_id in networks.local and networks.local[application_id].subnet is defined %}
|
||||
driver: bridge
|
||||
ipam:
|
||||
driver: default
|
||||
config:
|
||||
- subnet: {{networks.local[application_id].subnet}}
|
||||
{% endif %}
|
||||
{{ "\n" }}
|
@@ -0,0 +1,6 @@
|
||||
{# This needs to be included in docker-compose.yml which just contain a database volume #}
|
||||
{% if not applications | is_feature_enabled('central_database',application_id) %}
|
||||
volumes:
|
||||
database:
|
||||
{% endif %}
|
||||
{{ "\n" }}
|
6
roles/docker-compose/templates/volumes.yml.j2
Normal file
6
roles/docker-compose/templates/volumes.yml.j2
Normal file
@@ -0,0 +1,6 @@
|
||||
{# This template needs to be included in docker-compose.yml which contain a database and additional volumes #}
|
||||
volumes:
|
||||
{% if not applications | is_feature_enabled('central_database',application_id) %}
|
||||
database:
|
||||
{% endif %}
|
||||
{{ "\n" }}
|
Reference in New Issue
Block a user