Merge branch 'develop' into 'improve_upgrade_user_from_ap_id'
# Conflicts: # config/config.exs # docs/config.md
This commit is contained in:
commit
b4da2bc1d0
33 changed files with 1156 additions and 41 deletions
|
|
@ -58,6 +58,26 @@ Authentication is required and the user must be an admin.
|
|||
- `password`
|
||||
- Response: User’s nickname
|
||||
|
||||
## `/api/pleroma/admin/user/follow`
|
||||
### Make a user follow another user
|
||||
|
||||
- Methods: `POST`
|
||||
- Params:
|
||||
- `follower`: The nickname of the follower
|
||||
- `followed`: The nickname of the followed
|
||||
- Response:
|
||||
- "ok"
|
||||
|
||||
## `/api/pleroma/admin/user/unfollow`
|
||||
### Make a user unfollow another user
|
||||
|
||||
- Methods: `POST`
|
||||
- Params:
|
||||
- `follower`: The nickname of the follower
|
||||
- `followed`: The nickname of the followed
|
||||
- Response:
|
||||
- "ok"
|
||||
|
||||
## `/api/pleroma/admin/users/:nickname/toggle_activation`
|
||||
|
||||
### Toggle user activation
|
||||
|
|
|
|||
22
docs/api/prometheus.md
Normal file
22
docs/api/prometheus.md
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
# Prometheus Metrics
|
||||
|
||||
Pleroma includes support for exporting metrics via the [prometheus_ex](https://github.com/deadtrickster/prometheus.ex) library.
|
||||
|
||||
## `/api/pleroma/app_metrics`
|
||||
### Exports Prometheus application metrics
|
||||
* Method: `GET`
|
||||
* Authentication: not required
|
||||
* Params: none
|
||||
* Response: JSON
|
||||
|
||||
## Grafana
|
||||
### Config example
|
||||
The following is a config example to use with [Grafana](https://grafana.com)
|
||||
|
||||
```
|
||||
- job_name: 'beam'
|
||||
metrics_path: /api/pleroma/app_metrics
|
||||
scheme: https
|
||||
static_configs:
|
||||
- targets: ['pleroma.soykaf.com']
|
||||
```
|
||||
|
|
@ -105,7 +105,7 @@ config :pleroma, Pleroma.Mailer,
|
|||
* `safe_dm_mentions`: If set to true, only mentions at the beginning of a post will be used to address people in direct messages. This is to prevent accidental mentioning of people when talking about them (e.g. "@friend hey i really don't like @enemy"). (Default: `false`)
|
||||
|
||||
## :logger
|
||||
* `backends`: `:console` is used to send logs to stdout, `{ExSyslogger, :ex_syslogger}` to log to syslog
|
||||
* `backends`: `:console` is used to send logs to stdout, `{ExSyslogger, :ex_syslogger}` to log to syslog, and `Quack.Logger` to log to Slack
|
||||
|
||||
An example to enable ONLY ExSyslogger (f/ex in ``prod.secret.exs``) with info and debug suppressed:
|
||||
```
|
||||
|
|
@ -128,6 +128,24 @@ config :logger, :ex_syslogger,
|
|||
|
||||
See: [logger’s documentation](https://hexdocs.pm/logger/Logger.html) and [ex_syslogger’s documentation](https://hexdocs.pm/ex_syslogger/)
|
||||
|
||||
An example of logging info to local syslog, but warn to a Slack channel:
|
||||
```
|
||||
config :logger,
|
||||
backends: [ {ExSyslogger, :ex_syslogger}, Quack.Logger ],
|
||||
level: :info
|
||||
|
||||
config :logger, :ex_syslogger,
|
||||
level: :info,
|
||||
ident: "pleroma",
|
||||
format: "$metadata[$level] $message"
|
||||
|
||||
config :quack,
|
||||
level: :warn,
|
||||
meta: [:all],
|
||||
webhook_url: "https://hooks.slack.com/services/YOUR-API-KEY-HERE"
|
||||
```
|
||||
|
||||
See the [Quack Github](https://github.com/azohra/quack) for more details
|
||||
|
||||
## :frontend_configurations
|
||||
|
||||
|
|
@ -301,6 +319,7 @@ Pleroma has the following queues:
|
|||
* `federator_incoming` - Incoming federation
|
||||
* `mailer` - Email sender, see [`Pleroma.Mailer`](#pleroma-mailer)
|
||||
* `transmogrifier` - Transmogrifier
|
||||
* `scheduled_activities` - Scheduled activities, see [`Pleroma.ScheduledActivities`](#pleromascheduledactivity)
|
||||
|
||||
Example:
|
||||
|
||||
|
|
@ -396,3 +415,9 @@ Pleroma account will be created with the same name as the LDAP user name.
|
|||
|
||||
* `Pleroma.Web.Auth.PleromaAuthenticator`: default database authenticator
|
||||
* `Pleroma.Web.Auth.LDAPAuthenticator`: LDAP authentication
|
||||
|
||||
## Pleroma.ScheduledActivity
|
||||
|
||||
* `daily_user_limit`: the number of scheduled activities a user is allowed to create in a single day (Default: `25`)
|
||||
* `total_user_limit`: the number of scheduled activities a user is allowed to create in total (Default: `300`)
|
||||
* `enabled`: whether scheduled activities are sent to the job queue to be executed
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue