This is a tampermonkey/greasemonkey extension which:
- Highlights ao3 users listed as having blanket permission to podfic their works in rindle's fpslist in green
- Injects a link to the fpslist author profile page to their ao3 profile page
- Optionally filters out non-blanket permission author's works from search/bookmark results
You can contact me at BrickGrass#8455 on discord or @rustyshvl on twitter if you can't get it working and a github issue isn't appropriate.
In the unlikely event that the server I'm hosting dies, or if you just want to host a mirror, here are instructions for running the backend part of this script!
- Install nginx, whatever process manager you want (supervisor is good), a firewall, redis-server, postgresql, python3, pip3, and python venv
- Clone this repo
python3 -m venv venvinside the directory, activate the virtual environment with
source venv/bin/activateand then install all the python requirements with
pip install -r requirements.txt
- Set up your process manager to run this command using the python installation inside your venv
gunicorn -w 2 -k eventlet -b 127.0.0.1:6666 "fps_proxy:create_app()". My full config file is as follows:
[program:bp_proxy] directory=/home/george/bp_proxy command=/home/george/bp_proxy/venv/bin/gunicorn -w 2 -k eventlet -b 127.0.0.1:6666 "fps_proxy:create_app()" user=george autostart=true autorestart=true stopasgroup=true killasgroup=true stderr_logfile=/var/log/bp_proxy/bp_proxy.err.log stdout_logfile=/var/log/bp_proxy/bp_proxy.out.log
- Setup nginx as a reverse proxy that routes traffic from the /bp_api location to the port you ran the server on, in my example, 6666. Also, set up cors headers on all main requests (with your nginx config that is).
- Set up the config for your redis server, I'd recommend only having it accept connections from loopback (localhost, 127.0.0.1). It's used as a cache here, so you'll want to specify a maximum size and a key eviction policy, I use 250MB and allkeys-lfu. Once all this is sorted, set it up to run using a process manager also, probably use init.d for this. If you install via your package manager it'll likely do this as part of the installation, you'll just need to modify it to use your edited configuration instead of the default, have a look in /etc/init.d/redis-server that's probably the location.
- Set up a database and a user which has access to only that database with postgres. Make a copy of the file
config.json.examplerenaming it to
config.jsonand place the login details for that user into that file. Modify the file
db_config.pyso that the code below the __main__ statement runs the function
create_database(). Once you've run the file once and the database has it's tables added, restore
db_config.pyto it's previous state and set it up with cron to run on a sensible interval, I suggest once daily. This will query fpslist.org to see if the list of bp creators has changed since the last check.