| Both sides previous revisionPrevious revisionNext revision | Previous revision |
| servers:linux:nginx:friendica [2026/05/01 05:31] – [Etc] Sean Rhone | servers:linux:nginx:friendica [2026/06/05 06:31] (current) – Sean Rhone |
|---|
| * https://wiki.friendi.ca/docs/install#requirements | * https://wiki.friendi.ca/docs/install#requirements |
| |
| sudo zypper install php-composer2 php8-curl php8-gd php8-gmp php8-pdo php8-mbstring php8-intl php8-mysql php8-zip php8-openssl php8-fileinfo php8-posix php8-APCu php8-imagick | sudo zypper install php-composer2 php8-curl php8-gd php8-gmp php8-pdo php8-mbstring php8-intl php8-mysql php8-zip php8-openssl php8-fileinfo php8-posix |
| |
| ====== Download Source ====== | ====== Download Source ====== |
| sudo su 'wwwrun' -s '/bin/bash' | sudo su 'wwwrun' -s '/bin/bash' |
| |
| cd '/tmp' && '/usr/bin/composer' --working-dir='/srv/www/social' --no-cache install --no-dev | cd '/tmp' && '/usr/bin/composer' --working-dir='/srv/www/social' --no-cache install --no-dev --ignore-platform-req='ext-apcu' --ignore-platform-req='ext-imagick' |
| |
| exit | exit |
| |
| pm = "ondemand" | pm = "ondemand" |
| pm.max_children = "4" | pm.max_children = "8" |
| pm.process_idle_timeout = "30" | pm.process_idle_timeout = "30" |
| |
| * Navigation bar icon color: ''ffffff'' | * Navigation bar icon color: ''ffffff'' |
| * Link color: ''3d8bff'' | * Link color: ''3d8bff'' |
| * Set the background color: ''dedede'' | * Set the background color: ''fbfaf9'' |
| * Login page background color: ''484848'' | |
| |
| * Copy or paste schemestring: | * Copy or paste schemestring: |
| |
| <code>{"nav_bg":"#3d8bff","nav_icon_color":"#ffffff","link_color":"#3d8bff","background_color":"#dedede","background_image":"","contentbg_transp":"100","login_bg_image":"","login_bg_color":"#484848"}</code> | <code>{"nav_bg":"#3d8bff","nav_icon_color":"#ffffff","link_color":"#3d8bff","background_color":"#fbfaf9","background_image":"","contentbg_transp":"100"}</code> |
| |
| ===== local.config.php ===== | ===== local.config.php ===== |
| Type=oneshot | Type=oneshot |
| |
| WorkingDirectory=/srv/www/social | WorkingDirectory=/tmp |
| |
| ExecStart='/usr/bin/php' '/srv/www/social/bin/console.php' worker | ExecStart='/usr/bin/php' -c '/etc/php8/fpm/php-fpm.d/social.conf' '/srv/www/social/bin/console.php' worker |
| |
| # End</code> | # End</code> |
| Type=oneshot | Type=oneshot |
| |
| WorkingDirectory=/srv/www/social | WorkingDirectory=/tmp |
| Environment="COMPOSER_CACHE_DIR=/dev/null" | Environment="COMPOSER_CACHE_DIR=/dev/null" |
| | Environment="COMPOSER_DISCARD_CHANGES=true" |
| |
| ExecStart='/usr/bin/git' -C '/srv/www/social' reset --hard 'origin/develop' | ExecStart='/usr/bin/git' -C '/srv/www/social' reset --hard 'origin/develop' |
| ExecStart='/usr/bin/git' -C '/srv/www/social/addon' pull origin 'develop' --rebase | ExecStart='/usr/bin/git' -C '/srv/www/social/addon' pull origin 'develop' --rebase |
| |
| ExecStart='/usr/bin/composer' --working-dir='/srv/www/social' --no-cache install --no-dev | ExecStart='/usr/bin/php' -c '/etc/php8/fpm/php-fpm.d/social.conf' '/usr/bin/composer' --working-dir='/srv/www/social' --no-cache install --no-interaction --no-dev --ignore-platform-req='ext-apcu' --ignore-platform-req='ext-imagick' |
| |
| ExecStart='/usr/bin/php' '/srv/www/social/bin/console.php' dbstructure update --force | ExecStart='/usr/bin/php' -c '/etc/php8/fpm/php-fpm.d/social.conf' '/srv/www/social/bin/console.php' dbstructure update --force |
| ExecStart='/usr/bin/php' '/srv/www/social/bin/console.php' dbstructure drop --execute | ExecStart='/usr/bin/php' -c '/etc/php8/fpm/php-fpm.d/social.conf' '/srv/www/social/bin/console.php' dbstructure drop --execute |
| |
| ExecStartPost='/usr/bin/php' '/srv/www/social/bin/console.php' postupdate | ExecStartPost='/usr/bin/php' -c '/etc/php8/fpm/php-fpm.d/social.conf' '/srv/www/social/bin/console.php' postupdate |
| ExecStartPost='/usr/bin/sync' | |
| |
| # End</code> | # End</code> |
| |
| === Service === | === Service === |
| | |
| | * [[linux:notes:ext4|ext4 NAS]] |
| |
| mkdir -p ~/'backups' && sudo -e '/etc/systemd/system/social-fb.service' && sudo sed -i 's/CHANGEME/'$USER'/g' '/etc/systemd/system/social-fb.service' | mkdir -p ~/'backups' && sudo -e '/etc/systemd/system/social-fb.service' && sudo sed -i 's/CHANGEME/'$USER'/g' '/etc/systemd/system/social-fb.service' |
| Type=oneshot | Type=oneshot |
| |
| WorkingDirectory=/srv/www/social | WorkingDirectory=/tmp |
| |
| ExecStart='/usr/bin/bash' -c '"/usr/bin/tar" -czf "/home/CHANGEME/backups/friendica-files-auto-"$$(date +%%Y-%%m-%%d)".tar.gz" -C "/srv/www" "social"' | ExecStart='/usr/bin/bash' -c '"/usr/bin/tar" -czf "/mnt/NAS1/Servers/Scheduled Backups/friendica-files-auto-"$$(date +%%Y-%%m-%%d)".tar.gz" -C "/srv/www" "social"' |
| |
| ExecStartPost='/usr/bin/sync' | #ExecStart='/usr/bin/bash' -c '"/usr/bin/tar" -czf "/home/CHANGEME/backups/friendica-files-auto-"$$(date +%%Y-%%m-%%d)".tar.gz" -C "/srv/www" "social"' |
| |
| # End</code> | # End</code> |
| |
| === Service === | === Service === |
| | |
| | * [[linux:notes:ext4|ext4 NAS]] |
| |
| mkdir -p ~/'backups' && sudo mkdir -p '/srv/lib/mysql/tmp' && sudo -e '/etc/systemd/system/social-db.service' && sudo sed -i 's/'CHANGEME'/'$USER'/g' '/etc/systemd/system/social-db.service' | mkdir -p ~/'backups' && sudo mkdir -p '/srv/lib/mysql/tmp' && sudo -e '/etc/systemd/system/social-db.service' && sudo sed -i 's/'CHANGEME'/'$USER'/g' '/etc/systemd/system/social-db.service' |
| 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/friendica" --single-transaction --quick "friendica" -r "/home/CHANGEME/backups/friendica-database-auto-"$$(date +%%Y-%%m-%%d)".sql"' | ExecStart='/usr/bin/bash' -c '"/usr/bin/mariadb-dump" --defaults-extra-file="/srv/lib/mysql/auth/friendica" --single-transaction --quick "friendica" -r "/mnt/NAS1/Servers/Scheduled Backups/friendica-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/friendica" --single-transaction --quick "friendica" -r "/home/CHANGEME/backups/friendica-database-auto-"$$(date +%%Y-%%m-%%d)".sql"' |
| |
| # End</code> | # End</code> |
| Type=oneshot | Type=oneshot |
| |
| WorkingDirectory=/srv/www/social | WorkingDirectory=/tmp |
| |
| ExecStart='/usr/bin/git' -C '/srv/www/social' gc --aggressive --prune='all' | ExecStart='/usr/bin/git' -C '/srv/www/social' gc --aggressive --prune='all' |
| ExecStart='/usr/bin/git' -C '/srv/www/social/addon' fsck --full --strict | ExecStart='/usr/bin/git' -C '/srv/www/social/addon' fsck --full --strict |
| |
| ExecStart='/usr/bin/php' '/srv/www/social/bin/console.php' cache clear | ExecStart='/usr/bin/php' -c '/etc/php8/fpm/php-fpm.d/social.conf' '/srv/www/social/bin/console.php' cache clear |
| ExecStart='/usr/bin/php' '/srv/www/social/bin/console.php' clearavatarcache | ExecStart='/usr/bin/php' -c '/etc/php8/fpm/php-fpm.d/social.conf' '/srv/www/social/bin/console.php' clearavatarcache |
| | |
| ExecStartPost='/usr/bin/sync' | |
| |
| # End</code> | # End</code> |