This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| computing:pix3lfed [2026/03/01 17:57] – created oemb1905 | computing:pix3lfed [2026/08/05 17:30] (current) – oemb1905 | ||
|---|---|---|---|
| Line 16: | Line 16: | ||
| This tutorial provides users of Debian GNU/Linux with a roadmap for installing a Pixelfed instance. These isntructions are drawn from the [[https:// | This tutorial provides users of Debian GNU/Linux with a roadmap for installing a Pixelfed instance. These isntructions are drawn from the [[https:// | ||
| - | === Step 1: PHP Requirements === | + | === Step 1: LAMP Requirements === |
| - | Your LAMP stack might not have all php dependencies, | + | Your LAMP stack might not have all php dependencies, |
| sudo apt update | sudo apt update | ||
| - | sudo apt install php8.4-fpm php8.4-mysql php8.4-curl php8.4-gd php8.4-mbstring php8.4-xml php8.4-zip php8.4-bcmath php8.4-intl php8.4-redis php8.4-imagick php8.4-imap php8.4-ldap apache2 mariadb-server* imagick* redis* -y | + | sudo apt install php8.4-fpm php8.4-mysql php8.4-curl php8.4-gd php8.4-mbstring php8.4-xml php8.4-zip php8.4-bcmath php8.4-intl php8.4-redis php8.4-imagick php8.4-imap php8.4-ldap |
| sudo systemctl restart php8.4-fpm | sudo systemctl restart php8.4-fpm | ||
| Line 32: | Line 32: | ||
| sudo a2enmod setenvif | sudo a2enmod setenvif | ||
| sudo a2enmod mpm_event | sudo a2enmod mpm_event | ||
| + | sudo a2enmod rewrite | ||
| + | sudo a2enmod proxy | ||
| + | sudo a2enmod proxy_fcgi | ||
| + | sudo a2enmod mime | ||
| + | sudo a2enmod expires | ||
| + | sudo a2enmod deflate | ||
| sudo a2enconf php8.4-fpm | sudo a2enconf php8.4-fpm | ||
| sudo apache2ctl configtest | sudo apache2ctl configtest | ||
| Line 45: | Line 51: | ||
| pm.max_spare_servers = 18 | pm.max_spare_servers = 18 | ||
| | | ||
| - | Of course, adjust these to your use case and expected amount of users. The suggestions above should work well for 100-200 users with roughly 10-40 using services at the same time (or overlapping). | + | Of course, adjust these to your use case and expected amount of users. The suggestions above should work well for 100-200 users with roughly 10-40 using services at the same time (or overlapping). |
| - | === Step 2: Set up Your Database === | + | upload_max_filesize |
| + | post_max_size | ||
| + | memory_limit | ||
| + | max_execution_time | ||
| + | max_input_time | ||
| - | Create a new database named 'pixel' | + | My settings are very aggressive as there are some other things I do on this box. You can simply match Pixelfed's settings if you prefer. Okay, it's now time for DB creation. |
| - | mysql -u root -p | + | === Step 2: Set up Your Database === |
| - | </ | + | |
| - | Inside the MySQL shell, run: | + | Create a new database named ' |
| - | <code sql> | + | |
| - | CREATE DATABASE pixel CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci; | + | CREATE USER IF NOT EXISTS ' |
| - | CREATE USER IF NOT EXISTS ' | + | GRANT ALL PRIVILEGES ON pixel.* TO ' |
| - | GRANT ALL PRIVILEGES ON pixel.* TO ' | + | FLUSH PRIVILEGES; |
| - | FLUSH PRIVILEGES; | + | EXIT; |
| - | EXIT; | + | |
| - | </ | + | |
| - | This sets up a UTF-8 compatible database optimized for Pixelfed's schema. | + | Okay, now that the db is setup, it is time to download and configure |
| - | === Step 3: Nuke the Old Pixelfed | + | === Step 3: Download, Configure, & Initialize |
| - | <code bash> | + | Pixelfed is in its infancy so use the dev branch until the stable version is released: |
| - | sudo rm -rf / | + | |
| - | </ | + | |
| - | === Step 4: Clone Fresh Pixelfed from Git (Dev Branch) === | + | cd /var/www |
| + | git clone -b dev https:// | ||
| - | Clone the latest development branch from the official repository. The 'dev' branch often includes fixes and features not yet in stable. | + | Once it is downloaded, let's set up our permissions: |
| - | <code bash> | + | |
| - | cd /var/www | + | sudo chown www-data: |
| - | git clone -b dev https://github.com/ | + | sudo chown -R www-data:www-data ./ |
| - | </code> | + | sudo find . -type d -exec chmod 755 {} \; |
| + | sudo find . -type f -exec chmod 644 {} \; | ||
| + | sudo chmod -R 775 /var/www/pixelfed/storage /var/www/pixelfed/ | ||
| + | sudo chmod 600 /var/www/pixelfed/ | ||
| + | sudo chmod 600 /var/ | ||
| - | === Step 5: Set Permissions for the New Installation === | + | Once the permissions are setup, we can now initialize and setup Laravel, artisan, etc., and configure our virtual environment: |
| - | <code bash> | + | cd / |
| - | sudo chown -R www-data: | + | sudo -u www-data composer install --no-dev --optimize-autoloader |
| - | sudo chmod -R 775 /var/www/ | + | |
| - | </ | + | Now that dependencies are installed, let's make a copy of the example environment config with '' |
| - | This prevents permission errors during runtime, such as failed uploads or cache writes. | + | APP_NAME=" |
| + | APP_ENV=production | ||
| + | APP_KEY=generated with artisan later | ||
| + | APP_DEBUG=false | ||
| + | APP_URL=https:// | ||
| + | APP_DOMAIN=gnulinux.pics | ||
| + | ADMIN_DOMAIN=gnulinux.pics | ||
| + | SESSION_DOMAIN=gnulinux.pics | ||
| + | DB_CONNECTION=mysql | ||
| + | DB_HOST=127.0.0.1 | ||
| + | DB_PORT=3306 | ||
| + | DB_DATABASE=pixel | ||
| + | DB_USERNAME=pixel | ||
| + | DB_PASSWORD=strongpass | ||
| + | REDIS_HOST=127.0.0.1 | ||
| + | REDIS_PASSWORD=null | ||
| + | REDIS_PORT=6379 | ||
| + | REDIS_CLIENT=predis | ||
| + | REDIS_SCHEME=tcp | ||
| + | CACHE_DRIVER=redis | ||
| + | QUEUE_CONNECTION=redis | ||
| + | SESSION_DRIVER=redis | ||
| + | HORIZON_PREFIX=horizon- | ||
| + | MAIL_MAILER=smtp | ||
| + | MAIL_HOST=mail.haacksnetworking.org | ||
| + | MAIL_PORT=587 | ||
| + | MAIL_USERNAME=webmaster | ||
| + | MAIL_PASSWORD=strongpass | ||
| + | MAIL_ENCRYPTION=tls | ||
| + | MAIL_FROM_ADDRESS=webmaster@haacksnetworking.org | ||
| + | MAIL_FROM_NAME=" | ||
| + | ACTIVITY_PUB=true | ||
| + | AP_REMOTE_FOLLOW=true | ||
| + | AP_INBOX=true | ||
| + | AP_OUTBOX=true | ||
| + | AP_SHAREDINBOX=true | ||
| + | RELAY=true | ||
| + | OPEN_REGISTRATION=true | ||
| + | ENFORCE_EMAIL_VERIFICATION=true | ||
| + | PF_MAX_USERS=1000 | ||
| + | PF_OPTIMIZE_IMAGES=true | ||
| + | IMAGE_QUALITY=80 | ||
| + | MAX_PHOTO_SIZE=15000 | ||
| + | MAX_CAPTION_LENGTH=500 | ||
| + | MAX_ALBUM_LENGTH=4 | ||
| + | INSTANCE_DISCOVER_PUBLIC=true | ||
| + | PF_ENABLE_CLOUD=false | ||
| - | === Step 6: Install Dependencies with Composer === | + | Something like the above are the minimum settings one would want on spinup. Of course, you can add cloud storage and other stuff later if you so desire. You could also adjust it to use an off-site db and/or adjust your mailer to use sendgrid, etc. Personally, I prefer the db to be local as well as the mail server. I will eventually build a mail server on this instance and migrate the MAIL settings to using it instead, but for now, I've used an existing and working management mail server. It is now time to initialize the virtual environment using artisan: |
| - | <code bash> | + | |
| - | cd / | + | sudo -u www-data |
| - | sudo -u www-data | + | sudo -u www-data php artisan storage: |
| - | </ | + | ls -l / |
| + | sudo -u www-data php artisan key: | ||
| + | sudo -u www-data php artisan passport: | ||
| + | sudo -u www-data php artisan passport:install --force | ||
| + | sudo -u www-data php artisan horizon: | ||
| + | sudo -u www-data php artisan config: | ||
| + | sudo -u www-data php artisan route: | ||
| + | sudo -u www-data php artisan view: | ||
| + | sudo -u www-data php artisan | ||
| + | sudo -u www-data php artisan instance: | ||
| + | sudo -u www-data php artisan import: | ||
| - | This pulls in Laravel and other required packages without development tools for a production setup. | + | === Step 4: Additional |
| - | + | ||
| - | === Step 7: Configure the .env File === | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo nano / | + | |
| - | </ | + | |
| - | + | ||
| - | Paste or update with the following content (replace placeholders if needed, e.g., passwords, domains, or mail settings): | + | |
| - | + | ||
| - | <code ini> | + | |
| - | APP_NAME=" | + | |
| - | APP_ENV=production | + | |
| - | APP_KEY= # Generated later | + | |
| - | APP_DEBUG=false | + | |
| - | APP_URL=https:// | + | |
| - | APP_DOMAIN=gnulinux.pics | + | |
| - | ADMIN_DOMAIN=gnulinux.pics | + | |
| - | SESSION_DOMAIN=gnulinux.pics | + | |
| - | DB_CONNECTION=mysql | + | |
| - | DB_HOST=127.0.0.1 | + | |
| - | DB_PORT=3306 | + | |
| - | DB_DATABASE=pixel | + | |
| - | DB_USERNAME=pixel | + | |
| - | DB_PASSWORD=strongpass | + | |
| - | REDIS_HOST=127.0.0.1 | + | |
| - | REDIS_PASSWORD=null | + | |
| - | REDIS_PORT=6379 | + | |
| - | REDIS_CLIENT=predis | + | |
| - | REDIS_SCHEME=tcp | + | |
| - | CACHE_DRIVER=redis | + | |
| - | QUEUE_CONNECTION=redis | + | |
| - | SESSION_DRIVER=redis | + | |
| - | HORIZON_PREFIX=horizon- | + | |
| - | MAIL_MAILER=smtp | + | |
| - | MAIL_HOST=mail.haacksnetworking.org | + | |
| - | MAIL_PORT=587 | + | |
| - | MAIL_USERNAME=webmaster | + | |
| - | MAIL_PASSWORD=strongpass | + | |
| - | MAIL_ENCRYPTION=tls | + | |
| - | MAIL_FROM_ADDRESS=webmaster@haacksnetworking.org | + | |
| - | MAIL_FROM_NAME=" | + | |
| - | ACTIVITY_PUB=true | + | |
| - | AP_REMOTE_FOLLOW=true | + | |
| - | AP_INBOX=true | + | |
| - | AP_OUTBOX=true | + | |
| - | AP_SHAREDINBOX=true | + | |
| - | RELAY=true | + | |
| - | OPEN_REGISTRATION=true | + | |
| - | ENFORCE_EMAIL_VERIFICATION=true | + | |
| - | PF_MAX_USERS=1000 | + | |
| - | PF_OPTIMIZE_IMAGES=true | + | |
| - | IMAGE_QUALITY=80 | + | |
| - | MAX_PHOTO_SIZE=15000 | + | |
| - | MAX_CAPTION_LENGTH=500 | + | |
| - | MAX_ALBUM_LENGTH=4 | + | |
| - | INSTANCE_DISCOVER_PUBLIC=true | + | |
| - | PF_ENABLE_CLOUD=false | + | |
| - | FILESYSTEM_CLOUD=s3 | + | |
| - | # | + | |
| - | # | + | |
| - | # | + | |
| - | # | + | |
| - | #AWS_URL= | + | |
| - | # | + | |
| - | # | + | |
| - | </ | + | |
| - | + | ||
| - | Save and exit. | + | |
| - | + | ||
| - | === Step 8: Run Database Migrations === | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo -u www-data php artisan migrate --force | + | |
| - | </ | + | |
| - | + | ||
| - | === Step 9: Create the Public Storage Symlink (Critical for Images) === | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo -u www-data php artisan storage: | + | |
| - | </ | + | |
| - | + | ||
| - | Verify the symlink: | + | |
| - | + | ||
| - | <code bash> | + | |
| - | ls -l / | + | |
| - | </ | + | |
| - | + | ||
| - | Expected output: '' | + | |
| - | + | ||
| - | If images fail to display after uploads, recheck permissions: | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo chown -R www-data: | + | |
| - | sudo chmod -R 775 / | + | |
| - | #oauth bits require stronger perms | + | |
| - | sudo chmod 600 / | + | |
| - | sudo chmod 600 / | + | |
| - | </ | + | |
| - | + | ||
| - | === Step 10: Generate Application Key === | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo -u www-data php artisan key: | + | |
| - | </ | + | |
| - | + | ||
| - | === Step 11: Set Up Passport for OAuth === | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo -u www-data php artisan passport: | + | |
| - | sudo -u www-data php artisan passport: | + | |
| - | </ | + | |
| - | + | ||
| - | === Step 12: Set Up Horizon for Queue Worker === | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo -u www-data php artisan horizon: | + | |
| - | </ | + | |
| - | + | ||
| - | === Step 13: Cache Configurations, | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo -u www-data php artisan config: | + | |
| - | sudo -u www-data php artisan route: | + | |
| - | sudo -u www-data php artisan view: | + | |
| - | sudo -u www-data php artisan optimize | + | |
| - | </ | + | |
| - | + | ||
| - | === Step 14: Configure | + | |
| - | + | ||
| - | For the non-SSL site (HTTP redirect): | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo nano / | + | |
| - | </ | + | |
| - | + | ||
| - | Paste: | + | |
| - | + | ||
| - | <code apache> | + | |
| - | < | + | |
| - | ServerName gnulinux.pics | + | |
| - | RewriteEngine On | + | |
| - | RewriteCond %{SERVER_NAME} =gnulinux.pics | + | |
| - | RewriteRule ^ https:// | + | |
| - | </ | + | |
| - | </ | + | |
| - | + | ||
| - | For the SSL site: | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo nano / | + | |
| - | </ | + | |
| - | Paste: | + | During testing, I was having some spinning and other issues that seemed to stem from re-writes and overrides glitching a bit. For this reason, I added an override inside each vhost as an extra precaution. You also want to ensure that the ''/ |
| - | <code apache> | ||
| - | < | ||
| - | ServerName gnulinux.pics | ||
| - | SSLEngine on | ||
| - | SSLCertificateFile / | ||
| - | SSLCertificateKeyFile / | ||
| - | Include / | ||
| DocumentRoot / | DocumentRoot / | ||
| < | < | ||
| Line 268: | Line 176: | ||
| SetHandler " | SetHandler " | ||
| </ | </ | ||
| - | LimitRequestBody 524288000 | ||
| - | ErrorLog ${APACHE_LOG_DIR}/ | ||
| - | CustomLog ${APACHE_LOG_DIR}/ | ||
| - | </ | ||
| - | </ | ||
| - | Ensure | + | Pixelfed has a nested '' |
| <code bash> | <code bash> | ||
| - | sudo nano / | ||
| - | </ | ||
| - | |||
| - | In the ''< | ||
| - | |||
| - | <code apache> | ||
| < | < | ||
| Options Indexes FollowSymLinks | Options Indexes FollowSymLinks | ||
| - | AllowOverride All | + | AllowOverride All ### NOTE " |
| Require all granted | Require all granted | ||
| </ | </ | ||
| </ | </ | ||
| - | === Step 15: Configure | + | Additionally, |
| - | <code bash> | + | |
| - | sudo nano / | + | |
| - | </code> | + | RewriteEngine On |
| + | RewriteCond %{HTTP: | ||
| + | RewriteRule .* - [E=HTTP_AUTHORIZATION: | ||
| + | RewriteCond %{REQUEST_FILENAME} !-d | ||
| + | RewriteCond %{REQUEST_FILENAME} !-f | ||
| + | RewriteRule ^ index.php [L] | ||
| + | </IfModule> | ||
| - | Paste: | + | Now that apache is fully configured, let's create out systemd unit file. |
| - | <code apache> | + | === Step 5: Create and Enable Horizon Systemd Service === |
| - | Options +FollowSymLinks -Indexes | + | |
| - | RewriteEngine On | + | |
| - | RewriteCond %{HTTP: | + | |
| - | RewriteRule .* - [E=HTTP_AUTHORIZATION: | + | |
| - | RewriteCond %{REQUEST_FILENAME} !-d | + | |
| - | RewriteCond %{REQUEST_FILENAME} !-f | + | |
| - | RewriteRule ^ index.php [L] | + | |
| - | </ | + | |
| - | + | ||
| - | === Step 16: Create and Enable Horizon Systemd Service === | + | |
| - | + | ||
| - | <code bash> | + | |
| - | sudo nano / | + | |
| - | </ | + | |
| - | Paste: | + | First, let's create the unit file over in '' |
| - | < | + | < |
| [Unit] | [Unit] | ||
| - | Description=Pixelfed Horizon Queue Worker | + | Description=Pixelfed Horizon Queue Worker |
| + | Documentation=https:// | ||
| After=network.target apache2.service php8.4-fpm.service redis-server.service mariadb.service | After=network.target apache2.service php8.4-fpm.service redis-server.service mariadb.service | ||
| Wants=apache2.service php8.4-fpm.service redis-server.service mariadb.service | Wants=apache2.service php8.4-fpm.service redis-server.service mariadb.service | ||
| Line 328: | Line 218: | ||
| WorkingDirectory=/ | WorkingDirectory=/ | ||
| ExecStart=/ | ExecStart=/ | ||
| - | Restart=on-failure | + | Restart=always |
| - | RestartSec=5s | + | RestartSec=3 |
| + | StartLimitIntervalSec=0 | ||
| StandardOutput=journal | StandardOutput=journal | ||
| StandardError=journal | StandardError=journal | ||
| + | |||
| + | # Security hardening (less restrictive than before) | ||
| NoNewPrivileges=yes | NoNewPrivileges=yes | ||
| PrivateTmp=true | PrivateTmp=true | ||
| - | ProtectSystem=strict | + | ProtectSystem=full |
| ProtectHome=yes | ProtectHome=yes | ||
| + | ProtectKernelTunables=yes | ||
| + | ProtectKernelModules=yes | ||
| + | ProtectControlGroups=yes | ||
| + | RestrictSUIDSGID=yes | ||
| + | LockPersonality=yes | ||
| + | RestrictRealtime=yes | ||
| + | |||
| + | # Paths Horizon actually needs to write to | ||
| ReadWritePaths=/ | ReadWritePaths=/ | ||
| ReadWritePaths=/ | ReadWritePaths=/ | ||
| + | ReadWritePaths=/ | ||
| [Install] | [Install] | ||
| Line 343: | Line 245: | ||
| </ | </ | ||
| - | Then: | + | After you create the unit file, let's reload the daemon, restart the service and check for any errors. Restart all services and check a web browser to see if the instance resolves after restarting the services. |
| - | <code bash> | + | |
| - | sudo systemctl daemon-reload | + | sudo systemctl enable pixelfed.service |
| - | sudo systemctl enable pixelfed.service | + | sudo systemctl restart pixelfed.service |
| - | sudo systemctl restart pixelfed.service | + | sudo systemctl status pixelfed.service |
| - | sudo systemctl status pixelfed.service | + | journalctl -u pixelfed.service -n 50 |
| - | journalctl -u pixelfed.service -n 50 | + | sudo apache2ctl configtest |
| + | sudo systemctl reload apache2 | ||
| + | sudo systemctl restart apache2 php8.4-fpm pixelfed.service redis-server | ||
| + | |||
| + | Lastly, let's create our artisan workers so changes and updates happen automatically. Open up cron for www-data user with '' | ||
| + | |||
| + | < | ||
| + | * * * * * cd / | ||
| + | * * * * * cd / | ||
| + | * * * * * cd / | ||
| </ | </ | ||
| - | === Step 17: Restart All Services === | + | At this point, most essential lifts are done. As long as your landing page resolves, which it should by this stage, you can now move on to creating an admin user and then managing the instance via the GUI web panel: |
| - | <code bash> | + | === Step 6: User Creation & Instance Management === |
| - | sudo apache2ctl configtest | + | |
| - | sudo systemctl reload apache2 | + | |
| - | sudo systemctl restart apache2 php8.4-fpm pixelfed.service redis-server | + | |
| - | </ | + | |
| - | === Step 18: Create Admin User === | + | Let's create the admin user: |
| - | <code bash> | + | cd / |
| - | sudo -u www-data php artisan user:create | + | sudo -u www-data php artisan user:create |
| - | </ | + | |
| - | Follow prompts | + | Follow |
| - | | + | |
| - | * Username: admin | + | |
| - | | + | |
| - | | + | |
| - | | + | |
| - | === Step 19: Verification and Debugging Checks === | + | I am currently still working on getting the well-known to function correctly. I am unsure if the errors I am getting are due to the instance not yet being approved or if it is an error on my end. I will update here once confirmed: |
| - | | + | |
| - | <code bash> | + | |
| - | redis-cli ping | + | |
| - | redis-cli keys "horizon:*" | + | sudo -u www-data php artisan route:list | grep -i nodeinfo |
| - | sudo systemctl status redis-server | + | |
| - | sudo systemctl status pixelfed.service | + | |
| - | journalctl | + | |
| - | </ | + | |
| - | * Verify queue config: | + | For updating, something like the following is minimally required: |
| - | <code bash> | + | |
| - | sudo -u www-data php artisan config:show queue | grep default | + | |
| - | </ | + | |
| - | | + | |
| - | <code bash> | + | git pull origin dev |
| - | curl -s https:// | + | |
| - | curl -s https:// | + | |
| - | sudo -u www-data php artisan route:list | grep -i nodeinfo | + | sudo -u www-data php artisan config:cache |
| - | </ | + | sudo -u www-data php artisan route:cache |
| + | sudo systemctl restart pixelfed.service apache2 php8.4-fpm redis-server | ||
| - | * Federation test: | + | After updating, the instance will hose the permissions on the OAUTH bits, so I decided to make a fun script to reset all caches and perms as follows. I created '' |
| - | <code bash> | + | |
| - | curl -I https:// | + | |
| - | curl -I https://mastodon.social/ | + | |
| - | </ | + | |
| - | | + | |
| - | <code bash> | + | cd / |
| - | tail -n 100 / | + | echo " |
| - | </ | + | sleep 2s |
| + | echo "🔥 Clearing all old caches..." | ||
| + | sudo -u www-data php artisan optimize:clear | ||
| + | sudo -u www-data php artisan config: | ||
| + | | ||
| + | sudo -u www-data php artisan route: | ||
| + | sudo -u www-data php artisan view: | ||
| + | echo "🔥 Rebuilding fresh caches..." | ||
| + | sudo -u www-data php artisan config: | ||
| + | sudo -u www-data php artisan route: | ||
| + | sudo -u www-data php artisan view: | ||
| + | sudo -u www-data php artisan optimize | ||
| + | echo "🔥 Re-locking down the OAuth keys ..." | ||
| + | sudo chmod 600 / | ||
| + | sudo chmod 600 / | ||
| + | echo "🎉 Restarting services – bringing it all back online..." | ||
| + | sudo systemctl restart apache2 php8.4-fpm pixelfed.service redis-server | ||
| - | === Update Instructions === | + | This little script just helps me refresh everything if/when changes or adjustments need to be made. Once the instance gets approved and/or I have resolved the well-known federation and/or discovery stuff, I will post an update. Thanks all and happy hacking !! |
| - | <code bash> | + | ------------------------------------------- |
| - | cd / | + | |
| - | git pull origin dev | + | |
| - | sudo -u www-data composer install | + | |
| - | sudo -u www-data php artisan migrate | + | |
| - | sudo -u www-data php artisan config: | + | |
| - | sudo -u www-data php artisan route: | + | |
| - | sudo systemctl restart pixelfed.service apache2 php8.4-fpm redis-server | + | |
| - | </ | + | |
| - | Always check GitHub | + | === Debugging, Miscellaneous, |
| + | From here forward, I post miscellaneous debugging. To fix images in DMs failing, as per github #5217, #5365, #5496, I edited the db to accept wrongly submitted null values from the bad DM code: | ||
| + | |||
| + | mysql -u root -p | ||
| + | USE pixel; | ||
| + | ALTER TABLE statuses MODIFY COLUMN caption TEXT NULL; | ||
| + | EXIT; | ||
| + | |||
| + | This solves the issue and allows users to upload images inside their DMS. Here are the issues that helped me fix this: | ||
| + | |||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | |||
| + | I'm having an issue where the sql of the instance wrongly uses 19 for the re-issuance of the new client registration. Since this conflicts with 19 being used by the default personal client, it fails. After repeatedly messing with auto-increment according to github iALTER TABLE oauth_clients DROP PRIMARY KEY;ssues and seeing it fail once the keys and passport were re-initialized, | ||
| + | |||
| + | ALTER TABLE oauth_clients MODIFY id INT NOT NULL; | ||
| + | ALTER TABLE oauth_clients DROP PRIMARY KEY; | ||
| + | ALTER TABLE oauth_clients MODIFY id VARCHAR(255) NOT NULL; | ||
| + | ALTER TABLE oauth_clients ADD PRIMARY KEY (id); | ||
| + | DESCRIBE oauth_clients; | ||
| + | EXIT; | ||
| + | cd / | ||
| + | sudo -u www-data php artisan passport: | ||
| + | sudo -u www-data php artisan passport: | ||
| + | sudo / | ||
| + | |||
| + | Once I did this, the '' | ||
| + | |||
| + | https:// | ||
| + | https:// | ||
| + | |||
| + | More coming ... | ||
| - | --- // | + | --- // |