move NFS and database definitions to thecloud project
This commit is contained in:
parent
bf178f61c8
commit
c2b8131adc
4 changed files with 78 additions and 80 deletions
|
@ -1,25 +0,0 @@
|
|||
---
|
||||
- name: Create databases and NFS shares
|
||||
hosts: thecloud
|
||||
handlers:
|
||||
- name: reload nfs
|
||||
systemd:
|
||||
name: nfs-kernel-server
|
||||
state: restarted
|
||||
|
||||
tasks:
|
||||
- name: Create nfs shares
|
||||
with_items: "{{ nfs_shares }}"
|
||||
copy:
|
||||
dest: "/etc/exports.d/{{ item.name }}.exports"
|
||||
content: "{{ item.path }} *(rw,sync,no_subtree_check,no_root_squash)"
|
||||
notify: reload nfs
|
||||
|
||||
- name: Create databases
|
||||
with_items: "{{ database_passwords | dict2items }}"
|
||||
include_role:
|
||||
name: postgresql_database
|
||||
vars:
|
||||
database_name: "{{ item.key }}"
|
||||
database_user: "{{ item.key }}"
|
||||
database_password: "{{ item.value }}"
|
Reference in a new issue