Add guide to README

This commit is contained in:
Minecon724 2025-06-15 15:36:52 +02:00
commit 9532eeefcb
Signed by: Minecon724
GPG key ID: A02E6E67AB961189

View file

@ -1,7 +1,27 @@
### Preparation
You *can* connect directly to the Invidious database.
Only the following tables are used and must be kept:
- `playlist_videos`
- `playlists`
- `session_ids`
- `users`
You can delete the other ones.
For example, if you're exporting the database:
```bash
pg_dump -U kemal -t playlist_videos -t playlists -t session_ids -t users invidious -Fc -Z3 > invidious.sql
```
This saves 90% of storage compared to running pg_dump without args, in my case 432M -> 25M
Then:
```bash
cat invidious.sql | pg_restore -U kemal -d invidious
```
### Environment variables
- `QUART_SECRET_KEY`
- `DATABASE_URL`
- `ALTERNATIVE_INSTANCE_URL`, defaults to `https://redirect.invidious.io`
See the [.env.example](.env.example) file
### Health check
A `/health` endpoint is provided that returns `OK`
A `/health` endpoint is provided that always returns `OK`