Skip to content

Commit 743c360

Browse files
committed
Laraval queue:work doc updates
This adds the list of currently known queues to the worker job, and also suggests not to use it. People who DO want to do it themselves are left to burn their own bridges and make their own mistakes. This also added a few spaces and linting according to vscode's interpretation of what valid Markdown is, and fixes an accidental trailing backtick in the nginx section. Signed-Off-By: Rob Thomas <[email protected]>
1 parent b7a936f commit 743c360

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed

running-pixelfed/installation.md

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ Using a Unix socket is optional, but may provide faster access since it does not
116116

117117
### Email variables
118118

119-
By default, Pixelfed will not send any emails, but will instead write messages to the Laravel log.
119+
By default, Pixelfed will not send any emails, but will instead write messages to the Laravel log.
120120

121121
To setup a mailer for production deployments, you have several options for supported mail services. Pixelfed currently supports SMTP, Mailgun, Postmark, Amazon SES, and `sendmail` for sending emails to users.
122122

@@ -220,16 +220,19 @@ php artisan migrate --force
220220
```
221221

222222
If you want to enable support for location data:
223+
223224
```bash
224225
php artisan import:cities
225226
```
226227

227228
If you enabled ActivityPub federation:
229+
228230
```bash
229231
php artisan instance:actor
230232
```
231233

232234
If you enabled OAuth:
235+
233236
```bash
234237
php artisan passport:keys
235238
```
@@ -257,6 +260,7 @@ php artisan route:clear
257260
php artisan view:clear
258261
php artisan config:clear
259262
```
263+
260264
:::
261265

262266
### Job queueing
@@ -307,7 +311,7 @@ The example above assumes you are using MariaDB and Nginx, that your distributio
307311
- Replacing `nginx` with `apache`, or replacing `Requires` with `Wants` if you are not running in a production environment
308312
- Replacing `/usr/bin/php` or `/usr/share/webapps/pixelfed/artisan` with the correct paths, e.g. `/usr/bin/php8.1` or `/path/to/pixelfed/artisan`
309313
- Replacing `User=http` to reflect the app user, e.g. `User=pixelfed` or commenting this line in order to run in the system slice.
310-
:::
314+
:::
311315

312316
You can now use systemd to manage Pixelfed like any other background service:
313317

@@ -326,6 +330,7 @@ redirect_stderr=true
326330
stdout_logfile=/usr/share/webapps/pixelfed/horizon.log
327331
stopwaitsecs=3600
328332
```
333+
329334
::: tip
330335
**Using correct paths**
331336

@@ -341,10 +346,14 @@ sudo supervisorctl start pixelfed
341346
```
342347

343348
#### Using Queue Worker
344-
Pixelfed also includes a queue worker that will process new jobs as they are pushed onto the queue. You may run the worker using the `queue:work` command. Note that once the command has started, it will continue to run until it is manually stopped or you close your terminal:
349+
350+
Pixelfed also includes a queue worker that will process new jobs as they are pushed onto the queue. You may run the worker using the `queue:work` command. Note that once the command has started, it will continue to run until it is manually stopped or you close your terminal. This is not recommended for production use, but can be useful to debug any issues with workers.
351+
352+
**Warning**
353+
There are a large number of queues! The list of queues that horizon uses is stored in the [horizon.php](https://github.com/pixelfed/pixelfed/blob/dev/config/horizon.php#L180) configuration file. You should check that all queues in that file are listed on the worker command line, or jobs will not launch!
345354

346355
```bash
347-
php artisan queue:work
356+
php artisan queue:work --queue=high,default,follow,shared,inbox,feed,low,story,delete,mmo,intbg,groups,adelete,move,pushnotify
348357
```
349358

350359
Again, you can use Supervisor or systemd as described above, substituting `horizon` for `queue:work`.
@@ -376,6 +385,7 @@ You may need to replace `/usr/bin/php` or `/usr/share/webapps/pixelfed/artisan`
376385
To translate HTTPS web requests to PHP workers, you will need to configure a reverse proxy.
377386

378387
#### Apache
388+
379389
Pixelfed includes a `public/.htaccess` file that is used to provide URLs without the index.php front controller in the path. Before serving Pixelfed with Apache, be sure to enable the `mod_rewrite` module in your Apache configuration so the `.htaccess` file will be honored by the server.
380390

381391
If the `.htaccess` file that ships with Pixelfed does not work with your Apache installation, try this alternative:
@@ -463,7 +473,7 @@ Make sure to use the `/public` folder as your server root. For example:
463473
```nginx
464474
server {
465475
root /var/www/pixelfed/public;
466-
````
476+
```
467477

468478
If you set root to the install directory (example: `root /var/www/pixelfed;`) Pixelfed will not work.
469479
:::

0 commit comments

Comments
 (0)