blob: 3d9c5f46d340ff922ae8c03fc598ea35fb741a51 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
[![pipeline status](https://gitlab.com/gabrielgio/reddit-nextcloud-importer/badges/main/pipeline.svg)](https://gitlab.com/gabrielgio/reddit-nextcloud-importer/-/commits/main) [![coverage report](https://gitlab.com/gabrielgio/reddit-nextcloud-importer/badges/main/coverage.svg)](https://gitlab.com/gabrielgio/reddit-nextcloud-importer/-/commits/main)
# Reddit Nextcloud importer
A process to import images and videos from saved post on reddit to a instance of
Nextcloud.
# Environment variables
* `CLIENT_ID` and `CLIENT_SECRET`: crendentials needed to access Reddit's API.
To get those info you'd need:
* Go to [authorized application page](https://www.reddit.com/prefs/apps)
* Click on `Create another app...` button on the bottom of the page.
* Input the information and choose `script`.
* You can use `http://localhost:8080` on `redirect uri` field as you won't
need to use it.
* `REDDIT_USERNAME` and `REDDIT_PASSWORD`: user credenctial to access Reddit's
API. Because you chose `script` this user need to be listed as a developer in
the application page. To add a new user as a developer go to [authorized
application page](https://www.reddit.com/prefs/apps) and click on the `edit`
button on the application you just created. It will open a field `add
developer`.
* `NEXTCLOUD_HOST`: the host domain a port for the nextcloud instance.
* `NEXTCLOUD_USERNAME` and `NEXTCLOUD_PASSWORD`: user credential for the
nextcloud instance.
* `NEXTCLOUD_PATH`: root folder for where all the images will be saved.
|