mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-02-22 12:29:39 +01:00
Optimized locales and networks variable
This commit is contained in:
parent
30ccd30fa6
commit
83c84f6e86
@ -1,7 +1,9 @@
|
||||
# General
|
||||
pause_duration: "120" # Database delay to wait for the central database before continue tasks
|
||||
ip4_address: "127.0.0.1" # Change thie in inventory to the ip address of your server
|
||||
|
||||
backups_folder_path: "/Backups/" # Path to the backups folder
|
||||
timezone: "UTC"
|
||||
locale: "locale"
|
||||
|
||||
## Domain
|
||||
primary_domain_tld: "localhost" # Top Level Domain of the server
|
||||
|
@ -172,6 +172,10 @@ defaults_applications:
|
||||
postgres:
|
||||
database.version: "latest"
|
||||
|
||||
# Snipe-IT
|
||||
snipe-it:
|
||||
version: "latest"
|
||||
|
||||
## Taiga
|
||||
taiga:
|
||||
version: "latest"
|
||||
|
@ -44,6 +44,7 @@ ports:
|
||||
keycloak: 8032
|
||||
ldap: 8033
|
||||
phpmyadmin: 8034
|
||||
snipe-it: 8035
|
||||
bigbluebutton: 48087 # This port is predefined by bbb. @todo Try to change this to a 8XXX port
|
||||
# Ports which are exposed to the World Wide Web
|
||||
public:
|
||||
|
9
group_vars/all/10_networks.yml
Normal file
9
group_vars/all/10_networks.yml
Normal file
@ -0,0 +1,9 @@
|
||||
defaults_networks:
|
||||
internet:
|
||||
ip4: "127.0.0.1" # Change this in inventory to the ip address of your server
|
||||
ip6: "::01" # Change this in inventory to the ip address of your server
|
||||
local:
|
||||
mailu:
|
||||
dns: 192.168.203.254 # Address of the Mailu DNS server
|
||||
|
||||
|
@ -11,6 +11,9 @@
|
||||
- name: Merge application definitions
|
||||
set_fact:
|
||||
applications: "{{ defaults_applications | combine(applications | default({}, true), recursive=True) }}"
|
||||
- name: Merge networks definitions
|
||||
set_fact:
|
||||
networks: "{{ defaults_networks | combine(networks | default({}, true), recursive=True) }}"
|
||||
|
||||
- name: update device
|
||||
hosts: all
|
||||
|
@ -1,6 +1,6 @@
|
||||
# You should change this to match your reverse proxy DNS name and protocol
|
||||
APP_URL=https://{{domain}}
|
||||
LOCALE=en-US
|
||||
LOCALE={{locale}}
|
||||
|
||||
# Don't change this unless you rename your database container or use rootless podman, in case of using rootless podman you should set it to 127.0.0.1 (NOT localhost)
|
||||
DB_HOST={{database_host}}
|
||||
|
@ -41,12 +41,12 @@ FSESL_PASSWORD={{bigbluebutton_fsesl_password}}
|
||||
|
||||
DOMAIN={{domain}}
|
||||
|
||||
EXTERNAL_IPv4={{ip4_address}}
|
||||
EXTERNAL_IPv4={{{{networks.internet.ip4}}}}
|
||||
EXTERNAL_IPv6=
|
||||
|
||||
# STUN SERVER
|
||||
# stun.freeswitch.org
|
||||
STUN_IP={{ip4_address}}
|
||||
STUN_IP={{{{networks.internet.ip4}}}}
|
||||
STUN_PORT=3478
|
||||
|
||||
# TURN SERVER
|
||||
|
@ -34,7 +34,7 @@ env:
|
||||
LC_ALL: en_US.UTF-8
|
||||
LANG: en_US.UTF-8
|
||||
LANGUAGE: en_US.UTF-8
|
||||
# DISCOURSE_DEFAULT_LOCALE: en
|
||||
#DISCOURSE_DEFAULT_LOCALE: {{locale}} # Deactivated because not right format was selected @todo find right format
|
||||
|
||||
## How many concurrent web requests are supported? Depends on memory and CPU cores.
|
||||
## will be set automatically by bootstrap based on detected CPUs, or you can override
|
||||
|
@ -57,28 +57,6 @@ The role performs the following main tasks:
|
||||
3. **Start Docker containers:**
|
||||
- The role launches the Keycloak project using Docker Compose.
|
||||
|
||||
## Example: Usage 🚀
|
||||
|
||||
Here is an example of how to use this role in a playbook:
|
||||
|
||||
```yaml
|
||||
- name: Setup Keycloak with Docker
|
||||
hosts: all
|
||||
vars:
|
||||
domain: "auth.example.com"
|
||||
applications.keycloak.version: "21.1.0"
|
||||
applications.keycloak.administrator_username: "admin"
|
||||
keycloak_administrator_password: "securepassword"
|
||||
database_host: "db.example.com"
|
||||
database_name: "keycloak_db"
|
||||
database_username: "keycloak_user"
|
||||
database_password: "securedbpassword"
|
||||
http_port: 8080
|
||||
docker_restart_policy: "unless-stopped"
|
||||
roles:
|
||||
- docker-keycloak
|
||||
```
|
||||
|
||||
## More Information 📚
|
||||
|
||||
For more details about Keycloak, check out:
|
||||
|
@ -29,10 +29,10 @@
|
||||
dest: "{{docker_compose_instance_directory}}docker-compose.yml"
|
||||
notify: docker compose project setup
|
||||
|
||||
- name: add mailu.env
|
||||
- name: add .env
|
||||
template:
|
||||
src: "mailu.env.j2"
|
||||
dest: "{{docker_compose_instance_directory}}mailu.env"
|
||||
src: ".env.j2"
|
||||
dest: "{{docker_compose_instance_directory}}.env"
|
||||
notify: docker compose project setup
|
||||
|
||||
- name: flush docker service
|
||||
|
@ -7,29 +7,29 @@ services:
|
||||
# Core services
|
||||
resolver:
|
||||
image: ghcr.io/mailu/unbound:{{applications.mailu.version}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
restart: {{docker_restart_policy}}
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
ipv4_address: 192.168.203.254
|
||||
ipv4_address: {{networks.local.mailu.dns}}
|
||||
logging:
|
||||
driver: journald
|
||||
|
||||
front:
|
||||
image: ghcr.io/mailu/nginx:{{applications.mailu.version}}
|
||||
restart: {{docker_restart_policy}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
logging:
|
||||
driver: journald
|
||||
ports:
|
||||
- "127.0.0.1:{{ http_port }}:80"
|
||||
- "{{ ip4_address }}:25:25"
|
||||
- "{{ ip4_address }}:465:465"
|
||||
- "{{ ip4_address }}:587:587"
|
||||
- "{{ ip4_address }}:110:110"
|
||||
- "{{ ip4_address }}:995:995"
|
||||
- "{{ ip4_address }}:143:143"
|
||||
- "{{ ip4_address }}:993:993"
|
||||
- "{{ ip4_address }}:4190:4190"
|
||||
- "{{networks.internet.ip4}}:25:25"
|
||||
- "{{networks.internet.ip4}}:465:465"
|
||||
- "{{networks.internet.ip4}}:587:587"
|
||||
- "{{networks.internet.ip4}}:110:110"
|
||||
- "{{networks.internet.ip4}}:995:995"
|
||||
- "{{networks.internet.ip4}}:143:143"
|
||||
- "{{networks.internet.ip4}}:993:993"
|
||||
- "{{networks.internet.ip4}}:4190:4190"
|
||||
volumes:
|
||||
- "/etc/mailu/overrides/nginx:/overrides:ro"
|
||||
- "{{cert_mount_directory}}:/certs:ro"
|
||||
@ -40,12 +40,12 @@ services:
|
||||
webmail:
|
||||
radicale:
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
|
||||
admin:
|
||||
image: ghcr.io/mailu/admin:{{applications.mailu.version}}
|
||||
restart: {{docker_restart_policy}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
volumes:
|
||||
- "admin_data:/data"
|
||||
- "dkim:/dkim"
|
||||
@ -57,13 +57,13 @@ services:
|
||||
logging:
|
||||
driver: journald
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
|
||||
imap:
|
||||
image: ghcr.io/mailu/dovecot:{{applications.mailu.version}}
|
||||
restart: {{docker_restart_policy}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
volumes:
|
||||
- "dovecot_mail:/mail"
|
||||
- "/etc/mailu/overrides:/overrides:ro"
|
||||
@ -71,7 +71,7 @@ services:
|
||||
- front
|
||||
- resolver
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
logging:
|
||||
driver: journald
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
@ -79,7 +79,7 @@ services:
|
||||
smtp:
|
||||
image: ghcr.io/mailu/postfix:{{applications.mailu.version}}
|
||||
restart: {{docker_restart_policy}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
volumes:
|
||||
- "/etc/mailu/overrides:/overrides:ro"
|
||||
- "smtp_queue:/queue"
|
||||
@ -87,7 +87,7 @@ services:
|
||||
- front
|
||||
- resolver
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
logging:
|
||||
driver: journald
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
@ -99,14 +99,14 @@ services:
|
||||
depends_on:
|
||||
- resolver
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
noinet:
|
||||
|
||||
antispam:
|
||||
image: ghcr.io/mailu/rspamd:{{applications.mailu.version}}
|
||||
restart: {{docker_restart_policy}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
volumes:
|
||||
- "filter:/var/lib/rspamd"
|
||||
- "dkim:/dkim"
|
||||
@ -117,7 +117,7 @@ services:
|
||||
- antivirus
|
||||
- resolver
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
logging:
|
||||
driver: journald
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
@ -128,13 +128,13 @@ services:
|
||||
antivirus:
|
||||
image: clamav/clamav-debian:latest
|
||||
restart: {{docker_restart_policy}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
volumes:
|
||||
- "filter:/data"
|
||||
depends_on:
|
||||
- resolver
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
logging:
|
||||
driver: journald
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
@ -142,7 +142,7 @@ services:
|
||||
webdav:
|
||||
image: ghcr.io/mailu/radicale:{{applications.mailu.version}}
|
||||
restart: {{docker_restart_policy}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
volumes:
|
||||
- "webdav_data:/data"
|
||||
logging:
|
||||
@ -150,7 +150,7 @@ services:
|
||||
depends_on:
|
||||
- resolver
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
radicale:
|
||||
|
||||
@ -159,7 +159,7 @@ services:
|
||||
volumes:
|
||||
- "admin_data:/data"
|
||||
restart: {{docker_restart_policy}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
logging:
|
||||
driver: journald
|
||||
depends_on:
|
||||
@ -168,13 +168,13 @@ services:
|
||||
- imap
|
||||
- resolver
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
|
||||
webmail:
|
||||
image: ghcr.io/mailu/webmail:{{applications.mailu.version}}
|
||||
restart: {{docker_restart_policy}}
|
||||
env_file: mailu.env
|
||||
env_file: .env
|
||||
volumes:
|
||||
- "webmail_data:/data"
|
||||
- "/etc/mailu/overrides:/overrides:ro"
|
||||
@ -185,7 +185,7 @@ services:
|
||||
logging:
|
||||
driver: journald
|
||||
dns:
|
||||
- 192.168.203.254
|
||||
- {{networks.local.mailu.dns}}
|
||||
{% include 'templates/docker/container/networks.yml.j2' %}
|
||||
webmail:
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
matrix_servers:
|
||||
hosts:
|
||||
{{inventory_hostname}}:
|
||||
ansible_host: "{{ip4_address}}"
|
||||
ansible_host: "{{{{networks.internet.ip4}}}}"
|
||||
ansible_ssh_user: administrator
|
||||
become: true
|
||||
become_user: root
|
||||
|
@ -15,8 +15,8 @@ ENFORCE_EMAIL_VERIFICATION=false
|
||||
PF_MAX_USERS=1000
|
||||
OAUTH_ENABLED=true
|
||||
|
||||
APP_TIMEZONE=UTC
|
||||
APP_LOCALE=en
|
||||
APP_TIMEZONE={{timezone}}
|
||||
APP_LOCALE={{locale}}
|
||||
|
||||
## Pixelfed Tweaks
|
||||
LIMIT_ACCOUNT_SIZE=true
|
||||
|
Loading…
x
Reference in New Issue
Block a user