36 lines
1.9 KiB
Markdown
36 lines
1.9 KiB
Markdown
Logs into Nebula as the configured user, fetches available videos, and generates an RSS feed. No feed will be generated, if less than *feed_cache_time_seconds* seconds (set in config.json) have elapsed since last running this script.
|
|
|
|
Requirements
|
|
============
|
|
|
|
The following are needed to run this script:
|
|
- Python, version 3.8 to 3.10: I have tested 3.8.10 and 3.10.0. Older versions might work, but 3.6 is a hard minimum
|
|
- [Poetry](https://python-poetry.org): Not a hard requirement, I have included a requirements.txt which can be used to install dependencies with `pip install -r requirements.txt`
|
|
. I haven't tested this, and the list is auto-generated by poetry, using python 3.10
|
|
|
|
Installation
|
|
============
|
|
|
|
- Download or clone the repository.
|
|
- If you are using poetry, run `poetry install` in the `nebula-rss` directory.
|
|
- If you are not using poetry, run `pip install -r requirements.txt`. If that doesn't work, try manually installing the dependencies listed in `pyproject.toml`
|
|
- Copy `config_default.json` to `config.json`
|
|
|
|
Usage
|
|
=====
|
|
|
|
This assume you are inside the folder `nebula-rss`.
|
|
|
|
First, configure your username and password in `config.json`. You should also set your feed url and possibly adjust the path to the output file which will be generated.
|
|
Run `poetry run python main.py` to generate your feed. Alternatively, run `chmod +x ./main.py` to mark it as executable and then run `poetry run ./main.py`.
|
|
If you a not using poetry, run `python main.py` directly, or mark `main.py` as executable and run `./main.py`.
|
|
|
|
You will likely want to run the script regularly, to update the feed. I'm using the following crontab `* 0 * * * cd $HOME/nebula-rss; $HOME/.local/bin/poetry run ./main.py`, so that it runs once an hour.
|
|
|
|
I have not tested this on windows, but it should work without issues.
|
|
|
|
Notes
|
|
=====
|
|
|
|
This is an extremely hacky solution and uses the internal API. Naturally, this may break at any time.
|