mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-29 15:06:26 +02:00
Added draft for central postgres and mariadb. variables and networks still need to be adapted
This commit is contained in:
@@ -2,6 +2,11 @@
|
||||
- name: "include tasks nginx-docker-proxy-domain.yml"
|
||||
include_tasks: nginx-docker-proxy-domain.yml
|
||||
|
||||
- name: Create database in central MariaDB
|
||||
include_role:
|
||||
name: docker-mariadb
|
||||
when: enable_central_database | bool
|
||||
|
||||
- name: "create {{docker_compose_instance_directory}}"
|
||||
file:
|
||||
path: "{{docker_compose_instance_directory}}"
|
||||
|
@@ -1,14 +1,6 @@
|
||||
version: "3"
|
||||
|
||||
services:
|
||||
postgres:
|
||||
restart: always
|
||||
env_file: .env
|
||||
environment:
|
||||
- "POSTGRES_HOST_AUTH_METHOD=trust"
|
||||
image: postgres:15-alpine
|
||||
volumes:
|
||||
- database:/var/lib/postgresql/data
|
||||
|
||||
{% include 'templates/docker-redis-service.yml.j2' %}
|
||||
|
||||
@@ -18,7 +10,9 @@ services:
|
||||
restart: always
|
||||
image: funkwhale/api:${FUNKWHALE_VERSION:-latest}
|
||||
depends_on:
|
||||
{% if not ( enable_central_database | lower | bool ) %}
|
||||
- postgres
|
||||
% endif %}
|
||||
- redis
|
||||
env_file: .env
|
||||
command: celery -A funkwhale_api.taskapp worker -l INFO --concurrency=${CELERYD_CONCURRENCY-0}
|
||||
@@ -31,7 +25,9 @@ services:
|
||||
restart: always
|
||||
image: funkwhale/api:${FUNKWHALE_VERSION:-latest}
|
||||
depends_on:
|
||||
{% if not ( enable_central_database | lower | bool ) %}
|
||||
- postgres
|
||||
% endif %}
|
||||
- redis
|
||||
env_file: .env
|
||||
command: celery -A funkwhale_api.taskapp beat --pidfile= -l INFO
|
||||
@@ -65,7 +61,15 @@ services:
|
||||
ports:
|
||||
# override those variables in your .env file if needed
|
||||
- "${FUNKWHALE_API_IP}:${FUNKWHALE_API_PORT}:80"
|
||||
|
||||
{% if not ( enable_central_database | lower | bool ) %}
|
||||
{% include 'templates/docker-postgres-service.yml.j2' %}
|
||||
{% endif %}
|
||||
|
||||
volumes:
|
||||
data:
|
||||
redis:
|
||||
database:
|
||||
|
||||
{% if not ( enable_central_database | lower | bool ) %}
|
||||
database:
|
||||
{% endif %}
|
@@ -1,3 +1,7 @@
|
||||
docker_compose_project_name: "funkwhale"
|
||||
docker_compose_instance_directory: "{{path_docker_compose_instances}}{{docker_compose_project_name}}/"
|
||||
nginx_docker_reverse_proxy_extra_configuration: "client_max_body_size 512M;"
|
||||
database_databasename: "{{docker_compose_project_name}}"
|
||||
database_username: "{{docker_compose_project_name}}"
|
||||
database_password: "{{funkwhale_database_password}}"
|
||||
database_version: "{{ funkwhale_database_version | default(postgres_default_version) }}"
|
||||
|
Reference in New Issue
Block a user