mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2024-11-25 06:01:04 +01:00
Added docker baserow role
This commit is contained in:
parent
5a7141ab12
commit
8f715f8d81
@ -182,6 +182,14 @@
|
|||||||
domain: "tickets.{{top_domain}}"
|
domain: "tickets.{{top_domain}}"
|
||||||
http_port: 8015
|
http_port: 8015
|
||||||
mail_interface_http_port: 8016
|
mail_interface_http_port: 8016
|
||||||
|
- name: setup baserow hosts
|
||||||
|
hosts: baserow
|
||||||
|
become: true
|
||||||
|
roles:
|
||||||
|
- role: docker-baserow
|
||||||
|
vars:
|
||||||
|
domain: baserow.{{top_domain}}
|
||||||
|
http_port: 8017
|
||||||
- name: setup akaunting hosts
|
- name: setup akaunting hosts
|
||||||
hosts: akaunting
|
hosts: akaunting
|
||||||
become: true
|
become: true
|
||||||
|
5
roles/docker-baserow/README.md
Normal file
5
roles/docker-baserow/README.md
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
# docker baserow
|
||||||
|
|
||||||
|
This role allows the setup of [baserole](https://baserow.io/).
|
||||||
|
|
||||||
|
It was created with the help of [Chat GPT-4](https://chat.openai.com/share/556c2d7f-6b6f-4256-a646-a50529554efc).
|
8
roles/docker-baserow/handlers/main.yml
Normal file
8
roles/docker-baserow/handlers/main.yml
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
---
|
||||||
|
- name: recreate baserow
|
||||||
|
command:
|
||||||
|
cmd: docker-compose -p baserow up -d --force-recreate
|
||||||
|
chdir: "{{path_docker_compose_files}}baserow/"
|
||||||
|
environment:
|
||||||
|
COMPOSE_HTTP_TIMEOUT: 600
|
||||||
|
DOCKER_CLIENT_TIMEOUT: 600
|
25
roles/docker-baserow/tasks/main.yml
Normal file
25
roles/docker-baserow/tasks/main.yml
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
---
|
||||||
|
- name: recieve {{domain}} certificate
|
||||||
|
command: certbot certonly --agree-tos --email {{administrator_email}} --non-interactive --webroot -w /var/lib/letsencrypt/ -d {{domain}}
|
||||||
|
|
||||||
|
- name: configure {{domain}}.conf
|
||||||
|
template: src=roles/docker-reverse-proxy/templates/domain.conf.j2 dest=/etc/nginx/conf.d/{{domain}}.conf
|
||||||
|
notify: restart nginx
|
||||||
|
|
||||||
|
- name: "create {{docker_compose_path}}"
|
||||||
|
file:
|
||||||
|
path: "{{docker_compose_path}}"
|
||||||
|
state: directory
|
||||||
|
mode: 0755
|
||||||
|
|
||||||
|
- name: add docker-compose.yml
|
||||||
|
template: src=docker-compose.yml.j2 dest={{docker_compose_path}}docker-compose.yml
|
||||||
|
notify: recreate baserow
|
||||||
|
|
||||||
|
- name: add env
|
||||||
|
template:
|
||||||
|
src: env.j2
|
||||||
|
dest: "{{docker_compose_path}}env"
|
||||||
|
mode: '770'
|
||||||
|
force: yes
|
||||||
|
notify: recreate baserow
|
16
roles/docker-baserow/templates/docker-compose.yml.j2
Normal file
16
roles/docker-baserow/templates/docker-compose.yml.j2
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
version: '2'
|
||||||
|
|
||||||
|
services:
|
||||||
|
baserow:
|
||||||
|
image: baserow/baserow:1.19.1
|
||||||
|
restart: always
|
||||||
|
logging:
|
||||||
|
driver: journald
|
||||||
|
env_file:
|
||||||
|
- ./env
|
||||||
|
volumes:
|
||||||
|
- baserow_data:/baserow/data
|
||||||
|
ports:
|
||||||
|
- "{{http_port}}:80"
|
||||||
|
volumes:
|
||||||
|
baserow_data:
|
10
roles/docker-baserow/templates/env.j2
Normal file
10
roles/docker-baserow/templates/env.j2
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
# Public URL
|
||||||
|
BASEROW_PUBLIC_URL=https://{{ domain }}
|
||||||
|
|
||||||
|
# Email Server Configuration
|
||||||
|
EMAIL_SMTP=True
|
||||||
|
EMAIL_SMTP_HOST={{ system_email_host }}
|
||||||
|
EMAIL_SMTP_PORT={{ system_email_port }}
|
||||||
|
EMAIL_SMTP_USER={{ system_email_username }}
|
||||||
|
EMAIL_SMTP_PASSWORD={{ system_email_password }}
|
||||||
|
EMAIL_SMTP_USE_TLS=tls
|
1
roles/docker-baserow/vars/main.yml
Normal file
1
roles/docker-baserow/vars/main.yml
Normal file
@ -0,0 +1 @@
|
|||||||
|
docker_compose_path: "{{path_docker_compose_files}}baserow/"
|
Loading…
Reference in New Issue
Block a user