mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-29 15:06:26 +02:00
Restructured service und web role naming in inventor
This commit is contained in:
@@ -1,18 +1,18 @@
|
||||
# Database Docker Composition
|
||||
|
||||
This role combines the central RDBMS role (`svc-rdbms-central`) with Docker Compose to deliver a ready-to-use containerized database environment.
|
||||
This role combines the central RDBMS role (`cmp-rdbms-orchestrator`) with Docker Compose to deliver a ready-to-use containerized database environment.
|
||||
|
||||
## Features
|
||||
|
||||
- **Central RDBMS Integration**
|
||||
Includes the `svc-rdbms-central` role, which handles backups, restores, user and permission management for your relational database system (PostgreSQL, MariaDB, etc.).
|
||||
Includes the `cmp-rdbms-orchestrator` role, which handles backups, restores, user and permission management for your relational database system (PostgreSQL, MariaDB, etc.).
|
||||
|
||||
- **Docker Compose**
|
||||
Utilizes the standalone `docker-compose` role to define and bring up containers, networks, and volumes automatically.
|
||||
|
||||
- **Variable Load Order**
|
||||
1. Docker Compose variables (`roles/docker-compose/vars/docker-compose.yml`)
|
||||
2. Database variables (`roles/svc-rdbms-central/vars/database.yml`)
|
||||
2. Database variables (`roles/cmp-rdbms-orchestrator/vars/database.yml`)
|
||||
Ensures compose ports and volumes are defined before the database role consumes them.
|
||||
|
||||
The role will load both sub-roles and satisfy all dependencies transparently.
|
||||
@@ -22,4 +22,4 @@ The role will load both sub-roles and satisfy all dependencies transparently.
|
||||
1. **Set Fact** `database_application_id` to work around lazy‐loading ordering.
|
||||
2. **Include Vars** in the specified order.
|
||||
3. **Invoke** `docker-compose` role to create containers, networks, and volumes.
|
||||
4. **Invoke** `svc-rdbms-central` role to provision the database, backups, and users.
|
||||
4. **Invoke** `cmp-rdbms-orchestrator` role to provision the database, backups, and users.
|
@@ -14,4 +14,4 @@
|
||||
|
||||
- name: "Load central rdbms for {{ application_id }}"
|
||||
include_role:
|
||||
name: svc-rdbms-central
|
||||
name: cmp-rdbms-orchestrator
|
@@ -1,2 +1,2 @@
|
||||
cmp_db_docker_vars_file_db: "{{ playbook_dir }}/roles/svc-rdbms-central/vars/database.yml"
|
||||
cmp_db_docker_vars_file_db: "{{ playbook_dir }}/roles/cmp-rdbms-orchestrator/vars/database.yml"
|
||||
cmp_db_docker_vars_file_docker: "{{ playbook_dir }}/roles/docker-compose/vars/docker-compose.yml"
|
@@ -0,0 +1 @@
|
||||
{% include 'roles/cmp-rdbms-orchestrator/templates/services/' + database_type + '.yml.j2' %}
|
@@ -2,7 +2,7 @@
|
||||
services:
|
||||
{# Load Database #}
|
||||
{% if applications[application_id].docker.services.database.enabled | default(false) | bool %}
|
||||
{% include 'roles/svc-rdbms-central/templates/services/main.yml.j2' %}
|
||||
{% include 'roles/cmp-rdbms-orchestrator/templates/services/main.yml.j2' %}
|
||||
{% endif %}
|
||||
{# Load Redis #}
|
||||
{% if applications[application_id].docker.services.redis.enabled | default(false) | bool %}
|
||||
|
@@ -1 +0,0 @@
|
||||
{% include 'roles/svc-rdbms-central/templates/services/' + database_type + '.yml.j2' %}
|
@@ -25,5 +25,5 @@ galaxy_info:
|
||||
documentation: https://s.veen.world/cymais
|
||||
dependencies:
|
||||
- web-svc-legal
|
||||
- web-svc-assets
|
||||
- web-svc-asset
|
||||
- web-app-portfolio
|
@@ -1,5 +1,5 @@
|
||||
- name: "Load database variables for reset function"
|
||||
include_vars: "{{playbook_dir}}/roles/svc-rdbms-central/vars/main.yml"
|
||||
include_vars: "{{playbook_dir}}/roles/cmp-rdbms-orchestrator/vars/main.yml"
|
||||
|
||||
- name: "cleanup central database from {{application_id}}_default network"
|
||||
command:
|
||||
|
@@ -8,7 +8,7 @@ Enhance your sales and service processes with EspoCRM, an open-source CRM featur
|
||||
|
||||
This Ansible role deploys EspoCRM using Docker. It handles:
|
||||
|
||||
- MariaDB database provisioning via the `svc-rdbms-central` role
|
||||
- MariaDB database provisioning via the `cmp-rdbms-orchestrator` role
|
||||
- Nginx domain setup with WebSocket and reverse-proxy configuration
|
||||
- Environment variable management through Jinja2 templates
|
||||
- Docker Compose orchestration for **web**, **daemon**, and **websocket** services
|
||||
|
@@ -21,4 +21,3 @@ galaxy_info:
|
||||
run_after:
|
||||
- web-app-matomo
|
||||
- web-app-keycloak
|
||||
- svc-openldap
|
||||
|
@@ -21,5 +21,4 @@ galaxy_info:
|
||||
run_after:
|
||||
- web-app-matomo
|
||||
- web-app-keycloak
|
||||
- web-app-mailu
|
||||
- svc-openldap
|
||||
- web-app-mailu
|
@@ -20,5 +20,4 @@ galaxy_info:
|
||||
logo:
|
||||
class: "fa-solid fa-lock"
|
||||
run_after:
|
||||
- web-app-matomo
|
||||
- svc-openldap
|
||||
- web-app-matomo
|
@@ -17,6 +17,4 @@ galaxy_info:
|
||||
issue_tracker_url: "https://s.veen.world/cymaisissues"
|
||||
documentation: "https://s.veen.world/cymais"
|
||||
logo:
|
||||
class: "fa-solid fa-chart-line"
|
||||
run_after:
|
||||
- "svc-rdbms-postgres"
|
||||
class: "fa-solid fa-chart-line"
|
@@ -21,6 +21,4 @@ galaxy_info:
|
||||
run_after:
|
||||
- web-app-matomo
|
||||
- web-app-keycloak
|
||||
- web-app-mailu
|
||||
- svc-openldap
|
||||
- svc-rdbms-postgres
|
||||
- web-app-mailu
|
@@ -32,4 +32,3 @@ galaxy_info:
|
||||
- web-app-collabora
|
||||
- web-app-keycloak
|
||||
- web-app-mastodon
|
||||
- svc-rdbms-mariadb
|
||||
|
@@ -24,6 +24,5 @@ galaxy_info:
|
||||
logo:
|
||||
class: "fa-solid fa-user-lock"
|
||||
run_after:
|
||||
- svc-openldap
|
||||
- web-app-matomo
|
||||
- web-app-keycloak
|
||||
|
@@ -26,6 +26,5 @@ galaxy_info:
|
||||
logo:
|
||||
class: "fa-solid fa-database"
|
||||
run_after:
|
||||
- svc-rdbms-mariadb
|
||||
- web-app-matomo
|
||||
- web-app-keycloak
|
@@ -29,6 +29,5 @@ galaxy_info:
|
||||
logo:
|
||||
class: "fa-solid fa-tasks"
|
||||
run_after:
|
||||
- svc-rdbms-postgres
|
||||
- web-app-matomo
|
||||
- web-app-keycloak
|
||||
|
@@ -25,6 +25,5 @@ galaxy_info:
|
||||
logo:
|
||||
class: "fa-solid fa-link"
|
||||
run_after:
|
||||
- svc-rdbms-mariadb
|
||||
- web-app-matomo
|
||||
- web-app-keycloak
|
@@ -14,11 +14,11 @@ galaxy_info:
|
||||
- static
|
||||
repository: "https://github.com/kevinveenbirkenbach/cymais"
|
||||
issue_tracker_url: "https://github.com/kevinveenbirkenbach/cymais/issues"
|
||||
documentation: "https://github.com/kevinveenbirkenbach/cymais/tree/main/roles/web-svc-assets"
|
||||
documentation: "https://github.com/kevinveenbirkenbach/cymais/tree/main/roles/web-svc-asset"
|
||||
min_ansible_version: "2.9"
|
||||
platforms:
|
||||
- name: Any
|
||||
versions:
|
||||
- all
|
||||
dependencies:
|
||||
- web-svc-files
|
||||
- web-svc-file
|
@@ -1,3 +1,3 @@
|
||||
application_id: "assets-server" # Application identifier
|
||||
application_id: "asset" # Application identifier
|
||||
source_directory: "{{ applications[application_id].source_directory }}/" # Source directory from which the files are coming from
|
||||
target_directory: "{{ nginx.directories.data.files }}assets" # Directory to which the files will be copied
|
@@ -1,2 +1,2 @@
|
||||
application_id: "file-server"
|
||||
application_id: "file"
|
||||
domain: "{{ domains | get_domain(application_id) }}"
|
@@ -1,4 +1,4 @@
|
||||
application_id: "html-server"
|
||||
application_id: "html"
|
||||
domain: "{{domains | get_domain(application_id)}}"
|
||||
features:
|
||||
portfolio_iframe: true # Necessary for imprint loading
|
@@ -1 +1 @@
|
||||
application_id: "legal" # Application identifier
|
||||
application_id: "legal"
|
@@ -14,7 +14,7 @@ galaxy_info:
|
||||
- domains
|
||||
repository: "https://github.com/kevinveenbirkenbach/cymais"
|
||||
issue_tracker_url: "https://github.com/kevinveenbirkenbach/cymais/issues"
|
||||
documentation: "https://github.com/kevinveenbirkenbach/cymais/tree/main/roles/web-redirect-domains"
|
||||
documentation: "https://github.com/kevinveenbirkenbach/cymais/tree/main/roles/web-svc-redir-domains"
|
||||
min_ansible_version: "2.9"
|
||||
platforms:
|
||||
- name: Any
|
1
roles/web-svc-redir-domains/vars/main.yml
Normal file
1
roles/web-svc-redir-domains/vars/main.yml
Normal file
@@ -0,0 +1 @@
|
||||
application_id: "redir-domains"
|
@@ -7,7 +7,7 @@ Automates the creation of Nginx server blocks that redirect all `www.` subdomain
|
||||
This role will:
|
||||
- **Discover** existing `*.conf` vhosts in your Nginx servers directory
|
||||
- **Filter** domains with or without your `primary_domain`
|
||||
- **Generate** redirect rules via the `web-redirect-domains` role
|
||||
- **Generate** redirect rules via the `web-svc-redir-domains` role
|
||||
- **Optionally** include a wildcard redirect template (experimental) ⭐️
|
||||
- **Clean up** leftover configs when running in cleanup mode 🧹
|
||||
|
@@ -3,9 +3,9 @@
|
||||
set_fact:
|
||||
www_domains: "{{ current_play_domains_all | select('match', '^www\\.') | list }}"
|
||||
|
||||
- name: Include web-redirect-domains role for www-to-bare redirects
|
||||
- name: Include web-svc-redir-domains role for www-to-bare redirects
|
||||
include_role:
|
||||
name: web-redirect-domains
|
||||
name: web-svc-redir-domains
|
||||
vars:
|
||||
domain_mappings: "{{ www_domains
|
||||
| map('regex_replace',
|
1
roles/web-svc-redir-www/vars/main.yml
Normal file
1
roles/web-svc-redir-www/vars/main.yml
Normal file
@@ -0,0 +1 @@
|
||||
application_id: "redir-www"
|
Reference in New Issue
Block a user