mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2024-11-26 14:41:04 +01:00
Refactored folder structure
This commit is contained in:
parent
f33c63fbb2
commit
51e0a89247
@ -2,7 +2,7 @@
|
|||||||
- name: recreate mailu
|
- name: recreate mailu
|
||||||
command:
|
command:
|
||||||
cmd: docker-compose -p mailu up -d --force-recreate
|
cmd: docker-compose -p mailu up -d --force-recreate
|
||||||
chdir: /usr/local/bin/mailu/
|
chdir: /home/administrator/docker-compose/mailu/
|
||||||
- name: "restart deploy-letsencrypt-mailu.service"
|
- name: "restart deploy-letsencrypt-mailu.service"
|
||||||
systemd:
|
systemd:
|
||||||
name: deploy-letsencrypt-mailu.service
|
name: deploy-letsencrypt-mailu.service
|
||||||
|
@ -9,6 +9,18 @@
|
|||||||
template: src=roles/native-docker-reverse-proxy/templates/domain.conf.j2 dest=/etc/nginx/conf.d/{{domain}}.conf
|
template: src=roles/native-docker-reverse-proxy/templates/domain.conf.j2 dest=/etc/nginx/conf.d/{{domain}}.conf
|
||||||
notify: restart nginx
|
notify: restart nginx
|
||||||
|
|
||||||
|
- name: "create /home/administrator/docker-compose/mailu"
|
||||||
|
file:
|
||||||
|
path: "/home/administrator/docker-compose/mailu"
|
||||||
|
state: directory
|
||||||
|
mode: 0755
|
||||||
|
|
||||||
|
- name: "create /home/administrator/scripts/mailu"
|
||||||
|
file:
|
||||||
|
path: "/home/administrator/scripts/mailu"
|
||||||
|
state: directory
|
||||||
|
mode: 0755
|
||||||
|
|
||||||
- name: "create /etc/mailu/"
|
- name: "create /etc/mailu/"
|
||||||
file:
|
file:
|
||||||
path: "/etc/mailu"
|
path: "/etc/mailu"
|
||||||
@ -21,22 +33,16 @@
|
|||||||
state: directory
|
state: directory
|
||||||
mode: 0755
|
mode: 0755
|
||||||
|
|
||||||
- name: "create /usr/local/bin/mailu/"
|
|
||||||
file:
|
|
||||||
path: "/usr/local/bin/mailu"
|
|
||||||
state: directory
|
|
||||||
mode: 0755
|
|
||||||
|
|
||||||
- name: add docker-compose.yml
|
- name: add docker-compose.yml
|
||||||
template: src=docker-compose.yml.j2 dest=/usr/local/bin/mailu/docker-compose.yml
|
template: src=docker-compose.yml.j2 dest=/home/administrator/docker-compose/mailu/docker-compose.yml
|
||||||
notify: recreate mailu
|
notify: recreate mailu
|
||||||
|
|
||||||
- name: add mailu.env
|
- name: add mailu.env
|
||||||
template: src=mailu.env.j2 dest=/usr/local/bin/mailu/mailu.env
|
template: src=mailu.env.j2 dest=/home/administrator/docker-compose/mailu/mailu.env
|
||||||
notify: recreate mailu
|
notify: recreate mailu
|
||||||
|
|
||||||
- name: add deploy-letsencrypt-mailu.sh
|
- name: add deploy-letsencrypt-mailu.sh
|
||||||
template: src=deploy-letsencrypt-mailu.sh.j2 dest=/usr/local/bin/mailu/deploy-letsencrypt-mailu.sh
|
template: src=deploy-letsencrypt-mailu.sh.j2 dest=/home/administrator/scripts/mailu/deploy-letsencrypt-mailu.sh
|
||||||
|
|
||||||
- name: configure deploy-letsencrypt-mailu.service
|
- name: configure deploy-letsencrypt-mailu.service
|
||||||
template: src=deploy-letsencrypt-mailu.service.j2 dest=/etc/systemd/system/deploy-letsencrypt-mailu.service
|
template: src=deploy-letsencrypt-mailu.service.j2 dest=/etc/systemd/system/deploy-letsencrypt-mailu.service
|
||||||
|
@ -4,4 +4,4 @@ OnFailure=systemd-email@%n.service
|
|||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=oneshot
|
Type=oneshot
|
||||||
ExecStart=/usr/bin/bash /usr/local/bin/mailu/deploy-letsencrypt-mailu.sh
|
ExecStart=/usr/bin/bash /home/administrator/scripts/mailu/deploy-letsencrypt-mailu.sh
|
||||||
|
@ -17,6 +17,8 @@ services:
|
|||||||
MYSQL_USER: "mailu"
|
MYSQL_USER: "mailu"
|
||||||
MYSQL_PASSWORD: "{{mailu_database_password}}"
|
MYSQL_PASSWORD: "{{mailu_database_password}}"
|
||||||
MYSQL_RANDOM_ROOT_PASSWORD: 'yes'
|
MYSQL_RANDOM_ROOT_PASSWORD: 'yes'
|
||||||
|
COMPOSE_HTTP_TIMEOUT: 120
|
||||||
|
DOCKER_CLIENT_TIMEOUT: 120
|
||||||
volumes:
|
volumes:
|
||||||
- database:/var/lib/mysql
|
- database:/var/lib/mysql
|
||||||
|
|
||||||
|
@ -7,23 +7,22 @@
|
|||||||
notify: restart nginx
|
notify: restart nginx
|
||||||
|
|
||||||
# @todo rename
|
# @todo rename
|
||||||
- name: "create /usr/local/bin/docker-nextcloud/"
|
- name: "create /home/administrator/volumes/docker/nextcloud/"
|
||||||
file:
|
file:
|
||||||
path: "/usr/local/bin/docker-nextcloud"
|
path: "/home/administrator/volumes/docker/nextcloud"
|
||||||
state: directory
|
state: directory
|
||||||
mode: 0755
|
mode: 0755
|
||||||
|
|
||||||
- name: configure nginx.conf
|
- name: configure nginx.conf
|
||||||
template: src=templates/nginx.conf.j2 dest=/usr/local/bin/docker-nextcloud/nginx.conf
|
template: src=templates/nginx.conf.j2 dest=/home/administrator/volumes/docker/nextcloud/nginx.conf
|
||||||
notify: restart nginx
|
notify: restart nginx
|
||||||
|
|
||||||
# @todo rename
|
- name: "create /home/administrator/docker-compose/nextcloud/"
|
||||||
- name: "create /usr/local/bin/nextcloud/"
|
|
||||||
file:
|
file:
|
||||||
path: "/usr/local/bin/nextcloud"
|
path: "/home/administrator/docker-compose/nextcloud/"
|
||||||
state: directory
|
state: directory
|
||||||
mode: 0755
|
mode: 0755
|
||||||
|
|
||||||
- name: add docker-compose.yml
|
- name: add docker-compose.yml
|
||||||
template: src=docker-compose.yml.j2 dest=/usr/local/bin/nextcloud/docker-compose.yml
|
template: src=docker-compose.yml.j2 dest=/home/administrator/docker-compose/nextcloud/docker-compose.yml
|
||||||
notify: recreate nextcloud
|
notify: recreate nextcloud
|
||||||
|
@ -41,7 +41,7 @@ services:
|
|||||||
depends_on:
|
depends_on:
|
||||||
- application
|
- application
|
||||||
volumes:
|
volumes:
|
||||||
- /usr/local/bin/docker-nextcloud/nginx.conf:/etc/nginx/nginx.conf:ro
|
- /home/administrator/volumes/docker/nextcloud/nginx.conf:/etc/nginx/nginx.conf:ro
|
||||||
volumes_from:
|
volumes_from:
|
||||||
- application
|
- application
|
||||||
redis:
|
redis:
|
||||||
|
@ -15,3 +15,6 @@ cat > wp-config.php << EOF
|
|||||||
#content
|
#content
|
||||||
EOF
|
EOF
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## multiside
|
||||||
|
- https://multilingualpress.de/doku/wordpress-multisite-installieren-einrichten/
|
||||||
|
@ -1,2 +1,3 @@
|
|||||||
dependencies:
|
dependencies:
|
||||||
- native-docker-volume-backup
|
- native-docker-volume-backup
|
||||||
|
- native-user-administrator
|
||||||
|
@ -5,5 +5,21 @@
|
|||||||
state: present
|
state: present
|
||||||
notify: docker restart
|
notify: docker restart
|
||||||
|
|
||||||
|
- name: "create /home/administrator/docker-compose/"
|
||||||
|
file:
|
||||||
|
path: "/home/administrator/docker-compose"
|
||||||
|
state: directory
|
||||||
|
mode: 0700
|
||||||
|
owner: administrator
|
||||||
|
group: administrator
|
||||||
|
|
||||||
|
- name: "create /home/administrator/volumes/docker"
|
||||||
|
file:
|
||||||
|
path: "/home/administrator/volumes/docker"
|
||||||
|
state: directory
|
||||||
|
mode: 0700
|
||||||
|
owner: administrator
|
||||||
|
group: administrator
|
||||||
|
|
||||||
- name: flush docker service
|
- name: flush docker service
|
||||||
meta: flush_handlers
|
meta: flush_handlers
|
||||||
|
@ -24,3 +24,19 @@
|
|||||||
owner: root
|
owner: root
|
||||||
group: root
|
group: root
|
||||||
notify: sshd restart
|
notify: sshd restart
|
||||||
|
|
||||||
|
- name: "create /home/administrator/scripts/"
|
||||||
|
file:
|
||||||
|
path: "/home/administrator/scripts"
|
||||||
|
state: directory
|
||||||
|
owner: administrator
|
||||||
|
group: administrator
|
||||||
|
mode: 0700
|
||||||
|
|
||||||
|
- name: "create /home/administrator/volumes/"
|
||||||
|
file:
|
||||||
|
path: "/home/administrator/volumes"
|
||||||
|
state: directory
|
||||||
|
owner: administrator
|
||||||
|
group: administrator
|
||||||
|
mode: 0700
|
||||||
|
Loading…
Reference in New Issue
Block a user