Private
Public Access
2
0

Add NFS server/clients for share Wordpress

This commit is contained in:
2026-01-19 16:07:13 +03:00
parent 3d9fe37983
commit afa115e17a
11 changed files with 131 additions and 1 deletions

View File

@@ -154,6 +154,29 @@
tags:
- "mysql"
- name: NFS servers
hosts: nfs
gather_facts: false
vars_files:
- "vars/common.yml"
- "vars/secrets.yml"
vars:
nfs_server_exports:
- path: "/srv/wordpress"
owner: 1001
group: 33
clients:
- address: "www1"
options: "rw,no_root_squash"
- address: "www2"
options: "rw,no_root_squash"
- address: "www3"
options: "rw,no_root_squash"
roles:
- "nfs_server"
tags:
- "nfs"
- name: HTTP Servers
hosts: www
gather_facts: false
@@ -172,6 +195,12 @@
- "DNS:{{ ansible_fqdn }}"
- "DNS:{{ ansible_hostname }}"
- "IP:{{ ansible_default_ipv4.address }}"
nfs_client_mounts:
- mount_point: "/var/www/wordpress"
server: "nfs1:/srv/wordpress"
owner: 1001
group: 33
wordpress_create_master: "www1"
wordpress_site: "test.lab"
wordpress_url: "test.lab"
wordpress_site_title: "Lab Test"
@@ -194,6 +223,7 @@
check_http: "http://localhost:80/"
roles:
- "local_ca_certs"
- "nfs_client"
- "wordpress"
- "consul"
tags: