User Tools

Site Tools


servers:linux:nginx:piwigo

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
servers:linux:nginx:piwigo [2026/05/01 00:20] – [Server Block] Sean Rhoneservers:linux:nginx:piwigo [2026/05/01 05:24] (current) – [PHP-FPM Socket] Sean Rhone
Line 62: Line 62:
 pm.process_idle_timeout = "30" pm.process_idle_timeout = "30"
  
-php_value[log_errors] = "Off"+php_value[log_errors] = "0"
 php_value[error_reporting] = "~E_ALL" php_value[error_reporting] = "~E_ALL"
-php_value[display_errors] = "Off+php_value[display_errors] = "0
-php_value[display_startup_errors] = "Off+php_value[display_startup_errors] = "0
-php_value[html_errors] = "Off"+php_value[html_errors] = "0"
  
 php_value[session.save_path] = "/var/lib/php8/sessions" php_value[session.save_path] = "/var/lib/php8/sessions"
Line 172: Line 172:
 $conf['links'] = array( $conf['links'] = array(
   'https://realmofespionage.xyz' => 'Realm of Espionage',   'https://realmofespionage.xyz' => 'Realm of Espionage',
-  'https://wiki.realmofespionage.xyz/start' => 'RoE | Wiki',+  'https://wiki.realmofespionage.xyz' => 'RoE | Wiki',
   'https://blog.realmofespionage.xyz' => 'RoE | Blog',   'https://blog.realmofespionage.xyz' => 'RoE | Blog',
   'https://social.realmofespionage.xyz/profile/espionage724' => 'RoE | Social',   'https://social.realmofespionage.xyz/profile/espionage724' => 'RoE | Social',
   'https://forums.realmofespionage.xyz' => 'RoE | Forums',   'https://forums.realmofespionage.xyz' => 'RoE | Forums',
 +  'https://status.realmofespionage.xyz' => 'RoE | Status',
   'https://wiki.realmofespionage.xyz/user:espionage724' => 'Webmaster Info',   'https://wiki.realmofespionage.xyz/user:espionage724' => 'Webmaster Info',
   'https://wiki.realmofespionage.xyz/servers:linux:nginx:piwigo' => 'Instance Configuration Notes',   'https://wiki.realmofespionage.xyz/servers:linux:nginx:piwigo' => 'Instance Configuration Notes',
Line 185: Line 186:
 $conf['file_ext'] = array_merge( $conf['file_ext'] = array_merge(
   $conf['picture_ext'],   $conf['picture_ext'],
-  array('mp4','webmv','m4v','webm','mov')+  array('mp4')
   );   );
  
 // End // End
 ?></code> ?></code>
- 
-====== Scripts ====== 
- 
-===== Git Fix ===== 
- 
-  * :!: Set email for **both** ''user.email'' 
- 
-  sudo mkdir -p '/etc/nginx/scripts/media' && sudo -e '/etc/nginx/scripts/media/git-fix.sh' && sudo chmod '0500' '/etc/nginx/scripts/media/git-fix.sh' && sudo chown 'wwwrun':'www' '/etc/nginx/scripts/media/git-fix.sh' 
- 
-<code> 
-#!/bin/bash 
- 
-cd '/tmp' 
- 
-'/usr/bin/rm' -Rf '/srv/www/media/.git' 
-'/usr/bin/git' -C '/srv/www/media' init --initial-branch='master' 
-'/usr/bin/git' -C '/srv/www/media' add '.' 
- 
-######################################## 
-'/usr/bin/git' -C '/srv/www/media' config 'user.email' 'espionage724@x' 
-######################################## 
- 
-'/usr/bin/git' -C '/srv/www/media' commit --message='x' 
- 
-'/usr/bin/git' -C '/srv/www/media' remote add 'origin' 'https://github.com/Piwigo/Piwigo.git' 
-'/usr/bin/git' -C '/srv/www/media' pull --depth '1' --recurse-submodules 'origin' 'master' --rebase 
- 
-'/usr/bin/git' -C '/srv/www/media' reset --hard 'origin/master' 
-'/usr/bin/git' -C '/srv/www/media' gc --aggressive --prune='all' 
-'/usr/bin/git' -C '/srv/www/media' fsck --full --strict 
- 
-'/usr/bin/rm' -Rf '/srv/www/media/themes/bootstrap_darkroom/.git' 
-'/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' init --initial-branch='master' 
-'/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' add '.' 
- 
-######################################## 
-'/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' config 'user.email' 'espionage724@x' 
-######################################## 
- 
-'/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' commit --message='x' 
- 
-'/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' remote add 'origin' 'https://github.com/Piwigo/piwigo-bootstrap-darkroom.git' 
-'/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' pull --depth '1' --recurse-submodules 'origin' 'master' --rebase 
- 
-'/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' reset --hard 'origin/master' 
-'/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' gc --aggressive --prune='all' 
-'/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' fsck --full --strict 
- 
-# End</code> 
- 
-==== Execute ==== 
- 
-  sudo su 'wwwrun' -s '/bin/bash' 
- 
-  '/etc/nginx/scripts/media/git-fix.sh' 
- 
-  exit 
  
 ====== Services ====== ====== Services ======
Line 262: Line 206:
 Type=oneshot Type=oneshot
  
-WorkingDirectory=/srv/www/media+WorkingDirectory=/tmp
  
 ExecStart='/usr/bin/git' -C '/srv/www/media' reset --hard 'origin/master' ExecStart='/usr/bin/git' -C '/srv/www/media' reset --hard 'origin/master'
Line 269: Line 213:
 ExecStart='/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' reset --hard 'origin/master' ExecStart='/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' reset --hard 'origin/master'
 ExecStart='/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' pull origin 'master' --rebase ExecStart='/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' pull origin 'master' --rebase
- 
-ExecStartPost='/usr/bin/sync' 
  
 # End</code> # End</code>
Line 300: Line 242:
  
 === Service === === Service ===
 +
 +  * [[linux:notes:ext4|ext4 NAS]]
  
   mkdir -p ~/'backups' && sudo -e '/etc/systemd/system/media-fb.service' && sudo sed -i 's/CHANGEME/'$USER'/g' '/etc/systemd/system/media-fb.service'   mkdir -p ~/'backups' && sudo -e '/etc/systemd/system/media-fb.service' && sudo sed -i 's/CHANGEME/'$USER'/g' '/etc/systemd/system/media-fb.service'
Line 307: Line 251:
 Type=oneshot Type=oneshot
  
-WorkingDirectory=/srv/www/media+WorkingDirectory=/tmp
  
-ExecStart='/usr/bin/bash' -c '"/usr/bin/tar" -czf "/home/CHANGEME/backups/piwigo-files-auto-"$$(date +%%Y-%%m-%%d)".tar.gz" -C "/srv/www" "media"'+ExecStart='/usr/bin/bash' -c '"/usr/bin/tar" -czf "/mnt/NAS1/Servers/Scheduled Backups/piwigo-files-auto-"$$(date +%%Y-%%m-%%d)".tar.gz" -C "/srv/www" "media"'
  
-ExecStartPost='/usr/bin/sync'+#ExecStart='/usr/bin/bash' -c '"/usr/bin/tar" -czf "/home/CHANGEME/backups/piwigo-files-auto-"$$(date +%%Y-%%m-%%d)".tar.gz" -C "/srv/www" "media"'
  
 # End</code> # End</code>
Line 350: Line 294:
  
 === Service === === Service ===
 +
 +  * [[linux:notes:ext4|ext4 NAS]]
  
   mkdir -p ~/'backups' && sudo mkdir -p '/srv/lib/mysql/tmp' && sudo -e '/etc/systemd/system/media-db.service' && sudo sed -i 's/'CHANGEME'/'$USER'/g' '/etc/systemd/system/media-db.service'   mkdir -p ~/'backups' && sudo mkdir -p '/srv/lib/mysql/tmp' && sudo -e '/etc/systemd/system/media-db.service' && sudo sed -i 's/'CHANGEME'/'$USER'/g' '/etc/systemd/system/media-db.service'
Line 358: Line 304:
 Type=oneshot Type=oneshot
  
-WorkingDirectory=/srv/lib/mysql+WorkingDirectory=/tmp
  
-ExecStart='/usr/bin/bash' -c '"/usr/bin/mariadb-dump" --defaults-extra-file="/srv/lib/mysql/auth/piwigo" --single-transaction --quick "piwigo" -r "/home/CHANGEME/backups/piwigo-database-auto-"$$(date +%%Y-%%m-%%d)".sql"'+ExecStart='/usr/bin/bash' -c '"/usr/bin/mariadb-dump" --defaults-extra-file="/srv/lib/mysql/auth/piwigo" --single-transaction --quick "piwigo" -r "/mnt/NAS1/Servers/Scheduled Backups/piwigo-database-auto-"$$(date +%%Y-%%m-%%d)".sql"'
  
-ExecStartPost='/usr/bin/sync'+#ExecStart='/usr/bin/bash' -c '"/usr/bin/mariadb-dump" --defaults-extra-file="/srv/lib/mysql/auth/piwigo" --single-transaction --quick "piwigo" -r "/home/CHANGEME/backups/piwigo-database-auto-"$$(date +%%Y-%%m-%%d)".sql"'
  
 # End</code> # End</code>
Line 398: Line 344:
 Type=oneshot Type=oneshot
  
-WorkingDirectory=/srv/www/media+WorkingDirectory=/tmp
  
 ExecStart='/usr/bin/git' -C '/srv/www/media' gc --aggressive --prune='all' ExecStart='/usr/bin/git' -C '/srv/www/media' gc --aggressive --prune='all'
Line 405: Line 351:
 ExecStart='/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' gc --aggressive --prune='all' ExecStart='/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' gc --aggressive --prune='all'
 ExecStart='/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' fsck --full --strict ExecStart='/usr/bin/git' -C '/srv/www/media/themes/bootstrap_darkroom' fsck --full --strict
- 
-ExecStartPost='/usr/bin/sync' 
  
 # End</code> # End</code>
Line 542: Line 486:
  
 ===== MySQL Connection ===== ===== MySQL Connection =====
- 
-  * Windows uses ''127.0.0.1'' 
  
   sudo -e '/srv/www/media/local/config/database.inc.php' && sudo chown -v 'wwwrun':'www' '/srv/www/media/local/config/database.inc.php'   sudo -e '/srv/www/media/local/config/database.inc.php' && sudo chown -v 'wwwrun':'www' '/srv/www/media/local/config/database.inc.php'
Line 561: Line 503:
   rm -fv ~/'piwigo-files-'*'.tar.gz' ~/'piwigo'*'.sql'   rm -fv ~/'piwigo-files-'*'.tar.gz' ~/'piwigo'*'.sql'
  
-====== TODOs ======+====== Resources ====== 
 + 
 +===== Albums Formatting ===== 
 + 
 +  * :!: Using Emojis (like 8-) from [[https://emojipedia.org/smiling-face-with-sunglasses|Emojipedia]]) in comments caused a MySQL exception 
 + 
 +==== 4 Links ==== 
 + 
 +  * https://media.realmofespionage.xyz/index/category/
 + 
 +<code> 
 +<a href="https://wiki.realmofespionage.xyz/games;windows;2004scape_localhost" target="_blank" rel="noopener">Windows</a> | <a href="https://wiki.realmofespionage.xyz/games;linux;2004scape_localhost" target="_blank" rel="noopener">Linux</a> | <a href="https://wiki.realmofespionage.xyz/games;bsd;2004scape_localhost" target="_blank" rel="noopener">FreeBSD</a> | <a href="https://lostcity.rs/t/singleplayer-main-branch-scripts-and-desktop-start-launchers-on-windows-linux-freebsd/54" target="_blank" rel="noopener">Lost City Forums</a> 
 +</code> 
 + 
 +==== Single Link ==== 
 + 
 +  * https://media.realmofespionage.xyz/picture/268/category/17 
 + 
 +<code> 
 +<a href="https://wiki.realmofespionage.xyz/games;windows;dota_2_steamcmd" target="_blank" rel="noopener">Notes</a> 
 +</code> 
 + 
 +====== TODO ======
  
   * Show title on pictures (long titles get cut-off in navbar)   * Show title on pictures (long titles get cut-off in navbar)
   * AI ([[https://piwigo.org/forum/viewtopic.php?pid=192438#p192438|post]], [[https://github.com/Piwigo/Piwigo/commits/master/include/config_default.inc.php|config.inc.php]])   * AI ([[https://piwigo.org/forum/viewtopic.php?pid=192438#p192438|post]], [[https://github.com/Piwigo/Piwigo/commits/master/include/config_default.inc.php|config.inc.php]])
-  * :?: Below is remaining packages not installed from old installs+  * :?: Below is remaining packages not installed from old installs ((bz2/zlib seem installed with wiki; TODO: source for those being reqs))
  
   sudo dnf install libvorbis poppler-utils   sudo dnf install libvorbis poppler-utils
/srv/www/wiki/data/attic/servers/linux/nginx/piwigo.1777609237.txt.gz · Last modified: by Sean Rhone

Except where otherwise noted, content on this wiki is licensed under the following license: CC0 1.0 Universal
CC0 1.0 Universal Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki