fix apache config
This commit is contained in:
parent
ff95d9308d
commit
66c848525f
|
|
@ -1,10 +1,2 @@
|
|||
# Listen 8000
|
||||
|
||||
<IfModule ssl_module>
|
||||
Listen 443
|
||||
</IfModule>
|
||||
|
||||
<IfModule mod_gnutls.c>
|
||||
Listen 443
|
||||
</IfModule>
|
||||
|
||||
Listen 8000
|
||||
Listen 10000
|
||||
|
|
|
|||
|
|
@ -1,23 +1,23 @@
|
|||
Listen 8000
|
||||
|
||||
<VirtualHost localhost:8000>
|
||||
DocumentRoot /usr/share/wordpress
|
||||
<VirtualHost *:8000>
|
||||
SSLEngine off
|
||||
DocumentRoot /var/www/html/wordpress
|
||||
|
||||
Alias /wp-content /var/lib/wordpress/wp-content
|
||||
|
||||
<Directory /usr/share/wordpress>
|
||||
Options FollowSymLinks
|
||||
AllowOverride Limit Options FileInfo
|
||||
DirectoryIndex index.php
|
||||
Require all granted
|
||||
</Directory>
|
||||
|
||||
<Directory /var/lib/wordpress/wp-content>
|
||||
Options FollowSymLinks
|
||||
Require all granted
|
||||
</Directory>
|
||||
LogLevel info ssl:warn
|
||||
LogFormat "%{X-Forwarded-For}i %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
|
||||
|
||||
ErrorLog ${APACHE_LOG_DIR}/error.log
|
||||
CustomLog ${APACHE_LOG_DIR}/access.log combined
|
||||
|
||||
<Directory /var/www/html/wordpress>
|
||||
Options -Indexes
|
||||
AllowOverride None
|
||||
</Directory>
|
||||
|
||||
<IfModule mod_dir.c>
|
||||
DirectoryIndex index.php index.html
|
||||
</IfModule>
|
||||
|
||||
</VirtualHost>
|
||||
|
||||
|
|
|
|||
|
|
@ -15,16 +15,26 @@
|
|||
- php-mysql
|
||||
- php-xml
|
||||
- php-zip
|
||||
- wordpress
|
||||
- mariadb-server
|
||||
- python3-mysqldb
|
||||
|
||||
- name: create wordpress directory
|
||||
ansible.builtin.file:
|
||||
path: /var/www/html
|
||||
state: directory
|
||||
mode: '0755'
|
||||
|
||||
- name: extract wordpress
|
||||
ansible.builtin.unarchive:
|
||||
src: https://wordpress.org/latest.tar.gz
|
||||
remote_src: true
|
||||
dest: /var/www/html
|
||||
|
||||
- name: Import Wordpress database config
|
||||
become: yes
|
||||
ansible.builtin.template:
|
||||
src: "config-localhost.php.j2"
|
||||
dest: "/etc/wordpress/config-localhost.php"
|
||||
dest: "/var/www/html/wordpress/wp-config.php"
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0644
|
||||
|
|
|
|||
Loading…
Reference in New Issue