mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-15 08:30:46 +02:00
Optimized handler flushing
This commit is contained in:
parent
e2014b9b59
commit
004507e233
@ -1,8 +1,4 @@
|
|||||||
---
|
---
|
||||||
- name: "For '{{ application_id }}': load docker and db"
|
|
||||||
include_role:
|
|
||||||
name: cmp-db-docker
|
|
||||||
|
|
||||||
- name: "For '{{ application_id }}': include role to receive certs & do modification routines"
|
- name: "For '{{ application_id }}': include role to receive certs & do modification routines"
|
||||||
include_role:
|
include_role:
|
||||||
name: srv-web-7-6-composer
|
name: srv-web-7-6-composer
|
||||||
@ -12,6 +8,12 @@
|
|||||||
loop:
|
loop:
|
||||||
- "{{ domains | get_domain('web-app-mailu') }}"
|
- "{{ domains | get_domain('web-app-mailu') }}"
|
||||||
- "{{ domain }}"
|
- "{{ domain }}"
|
||||||
|
|
||||||
|
- name: "For '{{ application_id }}': load docker and db"
|
||||||
|
include_role:
|
||||||
|
name: cmp-db-docker
|
||||||
|
vars:
|
||||||
|
docker_compose_flush_handlers: true
|
||||||
|
|
||||||
- name: "For '{{ application_id }}': configure {{domains | get_domain(application_id)}}.conf"
|
- name: "For '{{ application_id }}': configure {{domains | get_domain(application_id)}}.conf"
|
||||||
template:
|
template:
|
||||||
|
@ -1,6 +1,3 @@
|
|||||||
- name: flush docker service
|
|
||||||
meta: flush_handlers
|
|
||||||
|
|
||||||
- name: "Execute migration for '{{ application_id }}'"
|
- name: "Execute migration for '{{ application_id }}'"
|
||||||
command:
|
command:
|
||||||
cmd: "docker-compose run --rm web bundle exec rails db:migrate"
|
cmd: "docker-compose run --rm web bundle exec rails db:migrate"
|
||||||
|
@ -1,8 +1,4 @@
|
|||||||
---
|
---
|
||||||
- name: "load docker and db for {{application_id}}"
|
|
||||||
include_role:
|
|
||||||
name: cmp-db-docker
|
|
||||||
|
|
||||||
- name: "Include setup for domain '{{ domain }}'"
|
- name: "Include setup for domain '{{ domain }}'"
|
||||||
include_role:
|
include_role:
|
||||||
name: srv-proxy-6-6-domain
|
name: srv-proxy-6-6-domain
|
||||||
@ -11,11 +7,17 @@
|
|||||||
loop_var: domain
|
loop_var: domain
|
||||||
vars:
|
vars:
|
||||||
http_port: "{{ ports.localhost.http[application_id] }}"
|
http_port: "{{ ports.localhost.http[application_id] }}"
|
||||||
location_ws: "/api/v1/streaming"
|
location_ws: "/api/v1/streaming"
|
||||||
ws_port: "{{ ports.localhost.websocket[application_id] }}"
|
ws_port: "{{ ports.localhost.websocket[application_id] }}"
|
||||||
client_max_body_size: "80m"
|
client_max_body_size: "80m"
|
||||||
vhost_flavour: "ws_generic"
|
vhost_flavour: "ws_generic"
|
||||||
|
|
||||||
|
- name: "load docker and db for {{application_id}}"
|
||||||
|
include_role:
|
||||||
|
name: cmp-db-docker
|
||||||
|
vars:
|
||||||
|
docker_compose_flush_handlers: true
|
||||||
|
|
||||||
- name: "start setup procedures for mastodon"
|
- name: "start setup procedures for mastodon"
|
||||||
include_tasks: 01_setup.yml
|
include_tasks: 01_setup.yml
|
||||||
when: mastodon_setup |bool
|
when: mastodon_setup | bool
|
@ -8,10 +8,6 @@
|
|||||||
bridges: "{{ bridges_configuration | filter_enabled_bridges(applications | get_app_conf(application_id, 'plugins', True)) }}"
|
bridges: "{{ bridges_configuration | filter_enabled_bridges(applications | get_app_conf(application_id, 'plugins', True)) }}"
|
||||||
changed_when: false
|
changed_when: false
|
||||||
|
|
||||||
- name: "load docker and db for {{application_id}}"
|
|
||||||
include_role:
|
|
||||||
name: cmp-db-docker
|
|
||||||
|
|
||||||
- name: "include role for {{application_id}} to receive certs & do modification routines"
|
- name: "include role for {{application_id}} to receive certs & do modification routines"
|
||||||
include_role:
|
include_role:
|
||||||
name: srv-web-7-6-composer
|
name: srv-web-7-6-composer
|
||||||
@ -19,6 +15,12 @@
|
|||||||
domain: "{{domains[application_id].synapse}}"
|
domain: "{{domains[application_id].synapse}}"
|
||||||
http_port: "{{ports.localhost.http['web-app-matrix_synapse']}}"
|
http_port: "{{ports.localhost.http['web-app-matrix_synapse']}}"
|
||||||
|
|
||||||
|
- name: "load docker and db for {{application_id}}"
|
||||||
|
include_role:
|
||||||
|
name: cmp-db-docker
|
||||||
|
vars:
|
||||||
|
docker_compose_flush_handlers: false
|
||||||
|
|
||||||
- name: create {{well_known_directory}}
|
- name: create {{well_known_directory}}
|
||||||
file:
|
file:
|
||||||
path: "{{well_known_directory}}"
|
path: "{{well_known_directory}}"
|
||||||
|
@ -18,6 +18,3 @@ matrix_project: "{{ application_id | get_entity_name }}"
|
|||||||
well_known_directory: "{{nginx.directories.data.well_known}}/matrix/"
|
well_known_directory: "{{nginx.directories.data.well_known}}/matrix/"
|
||||||
location_upload: "~ ^/_matrix/media/v3/"
|
location_upload: "~ ^/_matrix/media/v3/"
|
||||||
client_max_body_size: "{{ applications | get_app_conf(application_id, 'server.client_max_body_size') }}"
|
client_max_body_size: "{{ applications | get_app_conf(application_id, 'server.client_max_body_size') }}"
|
||||||
|
|
||||||
# Docker
|
|
||||||
docker_compose_flush_handlers: false
|
|
@ -6,16 +6,16 @@
|
|||||||
- include_tasks: utils/run_once.yml
|
- include_tasks: utils/run_once.yml
|
||||||
when: run_once_web_app_mybb is not defined
|
when: run_once_web_app_mybb is not defined
|
||||||
|
|
||||||
- name: "load docker and db for {{application_id}}"
|
|
||||||
include_role:
|
|
||||||
name: cmp-db-docker
|
|
||||||
|
|
||||||
- name: "include tasks setup-domain.yml with {{domains | get_domain(application_id)}}"
|
- name: "include tasks setup-domain.yml with {{domains | get_domain(application_id)}}"
|
||||||
include_tasks: setup-domain.yml
|
include_tasks: setup-domain.yml
|
||||||
loop: "{{ mybb_domains + [source_domain] }}"
|
loop: "{{ mybb_domains + [source_domain] }}"
|
||||||
loop_control:
|
loop_control:
|
||||||
loop_var: domain
|
loop_var: domain
|
||||||
|
|
||||||
|
- name: "load docker and db for {{application_id}}"
|
||||||
|
include_role:
|
||||||
|
name: cmp-db-docker
|
||||||
|
|
||||||
- name: "create {{docker_compose_instance_confd_directory}} and parent directories"
|
- name: "create {{docker_compose_instance_confd_directory}} and parent directories"
|
||||||
file:
|
file:
|
||||||
path: "{{docker_compose_instance_confd_directory}}"
|
path: "{{docker_compose_instance_confd_directory}}"
|
||||||
|
@ -1,8 +1,4 @@
|
|||||||
---
|
---
|
||||||
- name: "load docker and db for {{application_id}}"
|
|
||||||
include_role:
|
|
||||||
name: cmp-db-docker
|
|
||||||
|
|
||||||
- name: "include create-domains.yml for peertube"
|
- name: "include create-domains.yml for peertube"
|
||||||
include_tasks: create-domains.yml
|
include_tasks: create-domains.yml
|
||||||
loop: "{{ domains['web-app-peertube'] }}"
|
loop: "{{ domains['web-app-peertube'] }}"
|
||||||
@ -13,6 +9,10 @@
|
|||||||
http_port: "{{ ports.localhost.http[application_id] }}"
|
http_port: "{{ ports.localhost.http[application_id] }}"
|
||||||
ws_port: "{{ ports.localhost.http[application_id] }}"
|
ws_port: "{{ ports.localhost.http[application_id] }}"
|
||||||
|
|
||||||
|
- name: "load docker and db for {{application_id}}"
|
||||||
|
include_role:
|
||||||
|
name: cmp-db-docker
|
||||||
|
|
||||||
- name: "Install and activate auth-openid-connect plugin if OIDC is enabled"
|
- name: "Install and activate auth-openid-connect plugin if OIDC is enabled"
|
||||||
include_tasks: enable-oidc.yml
|
include_tasks: enable-oidc.yml
|
||||||
when: applications | get_app_conf(application_id, 'features.oidc', False)
|
when: applications | get_app_conf(application_id, 'features.oidc', False)
|
||||||
|
2
roles/web-app-pretix/Todo.md
Normal file
2
roles/web-app-pretix/Todo.md
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
# Todo
|
||||||
|
- This role needs to be fully implemented
|
@ -1,10 +1,7 @@
|
|||||||
---
|
---
|
||||||
- name: "load docker and db for {{application_id}}"
|
- block:
|
||||||
include_role:
|
- name: "load docker and db for {{application_id}}"
|
||||||
name: cmp-db-docker
|
include_role:
|
||||||
when: run_once_web_app_pretix is not defined
|
name: cmp-db-docker
|
||||||
|
- include_tasks: utils/run_once.yml
|
||||||
- name: run the pretix tasks once
|
|
||||||
set_fact:
|
|
||||||
run_once_web_app_pretix: true
|
|
||||||
when: run_once_web_app_pretix is not defined
|
when: run_once_web_app_pretix is not defined
|
||||||
|
@ -1,17 +1,11 @@
|
|||||||
---
|
---
|
||||||
- name: "load docker and db for {{application_id}}"
|
|
||||||
include_role:
|
|
||||||
name: cmp-db-docker
|
|
||||||
|
|
||||||
- name: "include role for {{application_id}} to receive certs & do modification routines"
|
- name: "include role for {{application_id}} to receive certs & do modification routines"
|
||||||
include_role:
|
include_role:
|
||||||
name: srv-web-7-6-composer
|
name: srv-web-7-6-composer
|
||||||
|
|
||||||
- name: configure {{domain}}.conf
|
- name: "load docker and db for {{application_id}}"
|
||||||
template:
|
include_role:
|
||||||
src: "templates/proxy.conf.j2"
|
name: cmp-db-docker
|
||||||
dest: "{{nginx.directories.http.servers}}{{domain}}.conf"
|
|
||||||
notify: restart openresty
|
|
||||||
|
|
||||||
- name: configure {{domain}}.conf
|
- name: configure {{domain}}.conf
|
||||||
template:
|
template:
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
- name: "Run WordPress core install via WP CLI"
|
- name: "Run WordPress core install via WP CLI"
|
||||||
|
no_log: "{{ MASK_CREDENTIALS_IN_LOGS | bool }}"
|
||||||
command: >
|
command: >
|
||||||
docker exec -u {{ wordpress_user }} {{ wordpress_container }}
|
docker exec -u {{ wordpress_user }} {{ wordpress_container }}
|
||||||
wp core install
|
wp core install
|
||||||
|
@ -1,10 +1,4 @@
|
|||||||
---
|
---
|
||||||
- name: "load docker and db for {{application_id}}"
|
|
||||||
include_role:
|
|
||||||
name: cmp-db-docker
|
|
||||||
vars:
|
|
||||||
docker_compose_flush_handlers: false
|
|
||||||
|
|
||||||
- name: "Include role srv-proxy-6-6-domain for {{ application_id }}"
|
- name: "Include role srv-proxy-6-6-domain for {{ application_id }}"
|
||||||
include_role:
|
include_role:
|
||||||
name: srv-proxy-6-6-domain
|
name: srv-proxy-6-6-domain
|
||||||
@ -15,6 +9,12 @@
|
|||||||
proxy_extra_configuration: "client_max_body_size {{ wordpress_max_upload_size }};"
|
proxy_extra_configuration: "client_max_body_size {{ wordpress_max_upload_size }};"
|
||||||
http_port: "{{ ports.localhost.http[application_id] }}"
|
http_port: "{{ ports.localhost.http[application_id] }}"
|
||||||
|
|
||||||
|
- name: "load docker and db for {{application_id}}"
|
||||||
|
include_role:
|
||||||
|
name: cmp-db-docker
|
||||||
|
vars:
|
||||||
|
docker_compose_flush_handlers: false
|
||||||
|
|
||||||
- name: "Transfering upload.ini to {{ docker_compose.directories.instance }}"
|
- name: "Transfering upload.ini to {{ docker_compose.directories.instance }}"
|
||||||
template:
|
template:
|
||||||
src: upload.ini.j2
|
src: upload.ini.j2
|
||||||
|
Loading…
x
Reference in New Issue
Block a user