nextload-core is a small dockerized service, that downloads videos from Youtube and a few other sites and then uploads them to your nextcloud instance.
The only requirements are:
- docker
- docker-compose
You can run nextload-core on the same host as nextcloud, but you don't need to. nextload-core can be installed on every system that supports docker and docker-compose.
As nextload-core accesses the nextcloud instance via webdav, we first need to create a new app token.
- Navigate to Profile -> Settings -> Security to create a new app token
Name your token nextload
and click "Generate new app password" to generate a new token.
Now copy the generate token to your clipboard...we will need that one a bit later.
-
download the
docker-compose.yml
file withwget https://raw.githubusercontent.com/bbernhard/nextload-core/master/env/docker/docker-compose.yml .
to your host system -
open the
docker-compose.yml
file with an editor and set theNEXTLOAD_URL
,NEXTLOAD_TOKEN
parameter accordingly. If everything is set correctly, the file should look like this:version: '3' services: nextload: image: bbernhard/nextload-core:latest restart: always environment: - NEXTCLOUD_TOKEN=ZgASA-cRxSg-HASAA-sd5Gz-qCtyr - NEXTCLOUD_URL=https://cloud.example.com - POLL_INTERVAL=5 volumes: - ./logs:/var/log/nextload-core
-
build and run docker-compose file with:
docker-compose up
resp.docker-compose up -d
if you want to start container in detached mode.
When the docker container starts up, it will create a new nextload
folder in your home directory.
Inside this folder, there are the nextload config file (config.yml
) and two folders (audios
, videos
).
If you want to create a new download task, just create a new .yml
file inside this directory. The actual name of the file doesn't matter, it just needs to have the ending .yml
.
In the text editor that opens, specify the url and the download format:
Per default, the docker container polls the nextcloud instance every 5 minutes (the POLL_INTERVAL
can be changed in the docker-compose.yml
file) for new download tasks. In case a new download task appeared, nextload-core downloads the file and then uploads it to your nextcloud account.
So, after 5+ minutes you should see the file appear either in the audios
or the videos
folder (depending on the format you specified).
In case a download task couldn't be processed, nextload-core creates a new file called task-file-name.error.txt
in your nextcloud instance containing the error message. So, if e.q: the task 1.yml
couldn't be processed, you will see the error log in the file 1.error.txt
.
see nextload-client for details
- Currently, only mp3 is supported as format. Shouldn't be hard to extend it, to also allow
*.mp4, *.ogg, ..
but it's still on the Todo list android & iOs app