servers:nginx:dokuwiki
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
servers:nginx:dokuwiki [2021/06/14 09:47] – Sean Rhone | servers:nginx:dokuwiki [2024/02/07 16:37] (current) – [Server Block] Sean Rhone | ||
---|---|---|---|
Line 7: | Line 7: | ||
===== Prerequisites ===== | ===== Prerequisites ===== | ||
- | * [[distros:fedora_workstation_gnome# | + | * [[distros:fedora_server|Fedora |
* [[servers: | * [[servers: | ||
* [[servers: | * [[servers: | ||
- | ====== | + | ====== |
- | **** | + | |
- | sudo git clone --branch ' | + | sudo dnf install php-gd php-sodium php-pecl-zip php-xml |
- | ===== SELinux | + | ====== Download Source ====== |
**** | **** | ||
- | sudo semanage fcontext --add --type 'httpd_sys_content_t' | + | |
====== nginx + PHP-FPM Configuration ====== | ====== nginx + PHP-FPM Configuration ====== | ||
Line 31: | Line 31: | ||
< | < | ||
[wiki] | [wiki] | ||
+ | |||
+ | ; User/Group | ||
user = nginx | user = nginx | ||
group = nginx | group = nginx | ||
+ | ; Socket | ||
listen = / | listen = / | ||
- | listen.owner = nginx | + | listen.acl_users |
- | listen.group | + | |
listen.allowed_clients = 127.0.0.1 | listen.allowed_clients = 127.0.0.1 | ||
+ | ; Process Management | ||
pm = ondemand | pm = ondemand | ||
pm.max_children = 4 | pm.max_children = 4 | ||
pm.process_idle_timeout = 30 | pm.process_idle_timeout = 30 | ||
- | php_value[date.timezone] = " | + | ; Fedora php.ini Defaults |
+ | php_value[session.save_handler] = " | ||
+ | php_value[session.save_path] = "/ | ||
+ | |||
+ | ; General | ||
+ | php_value[date.timezone] = " | ||
+ | ; | ||
+ | ; | ||
+ | ; | ||
+ | ; | ||
+ | ; | ||
+ | |||
+ | ; End</ | ||
===== FastCGI ===== | ===== FastCGI ===== | ||
Line 53: | Line 68: | ||
location ~ \.(php|phar)(/ | location ~ \.(php|phar)(/ | ||
fastcgi_split_path_info ^(.+\.(?: | fastcgi_split_path_info ^(.+\.(?: | ||
- | |||
fastcgi_intercept_errors on; | fastcgi_intercept_errors on; | ||
fastcgi_index doku.php; | fastcgi_index doku.php; | ||
include fastcgi_params; | include fastcgi_params; | ||
- | fastcgi_param SCRIPT_FILENAME | + | fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; |
fastcgi_param PATH_INFO $fastcgi_path_info; | fastcgi_param PATH_INFO $fastcgi_path_info; | ||
+ | fastcgi_param HTTPS on; | ||
fastcgi_pass unix:/ | fastcgi_pass unix:/ | ||
}</ | }</ | ||
Line 106: | Line 121: | ||
====== Initial Setup ====== | ====== Initial Setup ====== | ||
+ | |||
+ | * :!: TODO: https:// | ||
* https:// | * https:// | ||
Line 111: | Line 128: | ||
====== Settings ====== | ====== Settings ====== | ||
- | ===== Code Box Click Issue ===== | + | ===== Plugins |
- | * https://github.com/nicolasprigent/ | + | * https://www.dokuwiki.org/plugin:searchindex |
- | * https:// | + | |
===== Template Style Settings ===== | ===== Template Style Settings ===== | ||
Line 131: | Line 147: | ||
===== URL Rewrite ===== | ===== URL Rewrite ===== | ||
- | * Admin -> Configuration Settings | + | * Admin -> Configuration Settings |
- | | + | |
+ | .htaccess | ||
===== Double-hyphen Convert Disable ===== | ===== Double-hyphen Convert Disable ===== | ||
Line 138: | Line 155: | ||
* This prevents -- from becoming a – (long hyphen), which breaks some command' | * This prevents -- from becoming a – (long hyphen), which breaks some command' | ||
- | echo ' | + | echo ' |
====== Services ====== | ====== Services ====== | ||
Line 150: | Line 167: | ||
< | < | ||
[Service] | [Service] | ||
- | User=wwwrun | + | User=nginx |
- | Group=www | + | Group=nginx |
Type=oneshot | Type=oneshot | ||
ExecStart='/ | ExecStart='/ | ||
- | ExecStartPost='/ | + | ExecStartPost='/ |
+ | ExecStartPost='/ | ||
+ | |||
+ | # End</ | ||
==== Timer ==== | ==== Timer ==== | ||
- | * Every day at '' | + | * Every day at '' |
sudo -e '/ | sudo -e '/ | ||
Line 169: | Line 189: | ||
[Timer] | [Timer] | ||
- | OnCalendar=*-*-* | + | OnCalendar=*-*-* 00:30:00 |
Persistent=true | Persistent=true | ||
[Install] | [Install] | ||
- | WantedBy=timers.target</ | + | WantedBy=timers.target |
+ | |||
+ | # End</ | ||
===== Maintenance ===== | ===== Maintenance ===== | ||
Line 187: | Line 209: | ||
< | < | ||
[Service] | [Service] | ||
- | User=wwwrun | + | User=nginx |
- | Group=www | + | Group=nginx |
Type=oneshot | Type=oneshot | ||
WorkingDirectory=/ | WorkingDirectory=/ | ||
Line 196: | Line 218: | ||
ExecStart='/ | ExecStart='/ | ||
ExecStart='/ | ExecStart='/ | ||
- | ExecStartPost='/ | + | ExecStartPost='/ |
+ | |||
+ | # End</ | ||
==== Timer ==== | ==== Timer ==== | ||
- | * '' | + | * '' |
sudo -e '/ | sudo -e '/ | ||
Line 209: | Line 233: | ||
[Timer] | [Timer] | ||
- | OnCalendar=*-*-01 01:20:00 | + | OnCalendar=*-*-01 01:00:00 |
Persistent=true | Persistent=true | ||
[Install] | [Install] | ||
- | WantedBy=timers.target</ | + | WantedBy=timers.target |
+ | |||
+ | # End</ | ||
===== Backup ===== | ===== Backup ===== | ||
- | * This backs up an archive to the local disk and [[distros: | + | * This backs up an archive to the local disk and to a NAS |
==== Service ==== | ==== Service ==== | ||
+ | |||
+ | * :!: The extra '' | ||
mkdir -p ~/' | mkdir -p ~/' | ||
Line 227: | Line 255: | ||
Type=oneshot | Type=oneshot | ||
WorkingDirectory=/ | WorkingDirectory=/ | ||
- | ExecStart='/ | + | ExecStart='/ |
- | ExecStartPost='/ | + | # |
+ | # | ||
+ | ExecStartPost='/ | ||
+ | |||
+ | # End</ | ||
==== Timer ==== | ==== Timer ==== | ||
- | * Every day at '' | + | * Every day at '' |
sudo -e '/ | sudo -e '/ | ||
Line 241: | Line 273: | ||
[Timer] | [Timer] | ||
- | OnCalendar=*-*-* 01:50:00 | + | OnCalendar=*-*-* 01:30:00 |
Persistent=true | Persistent=true | ||
[Install] | [Install] | ||
- | WantedBy=timers.target</ | + | WantedBy=timers.target |
+ | |||
+ | # End</ | ||
====== Backup ====== | ====== Backup ====== | ||
Line 301: | Line 335: | ||
**** | **** | ||
- | cd '/ | + | cd '/ |
==== Start nginx ==== | ==== Start nginx ==== | ||
Line 314: | Line 348: | ||
rm -R ~/' | rm -R ~/' | ||
+ |
/var/www/wiki/data/attic/servers/nginx/dokuwiki.1623678460.txt.gz · Last modified: 2021/06/14 09:47 by Sean Rhone