forked from rDrama/rDrama
This code runs https://rdrama.net and https://watchpeopledie.tv
Consider the case of the current /notifications filter condition: WHERE ... NOT ((comments.sentto = 2) AND (users.is_muted)) SELECT 1 WHERE NOT ((null = 2) AND (true)); ⇒ 0 rows SELECT 1 WHERE NOT ((1 = 2) AND (true)); ⇒ 1 row SELECT 1 WHERE NOT ((2 = 2) AND (true)); ⇒ 0 rows We want the first expression, where comments.sentto = null, to evaluate to false, not to null, so it negates to true. Behavior as written is: SELECT 1 WHERE NOT ((null = 2) AND (true)); → SELECT 1 WHERE NOT (null AND true); → SELECT 1 WHERE NOT null; → SELECT 1 WHERE null; Which guarantees a null return set. If we check first for non-nullity: SELECT 1 WHERE NOT ((null IS NOT null) AND (null = 2) AND (true)); ⇒ 1 SELECT 1 WHERE NOT ((1 IS NOT null) AND (1 = 2) AND (true)); ⇒ 1 SELECT 1 WHERE NOT ((2 IS NOT null) AND (2 = 2) AND (true)); ⇒ 0 |
||
---|---|---|
.github | ||
chat | ||
files | ||
.gitattributes | ||
.gitignore | ||
CODE_OF_CONDUCT.md | ||
Dockerfile | ||
LICENSE | ||
docker-compose.yml | ||
env | ||
gunicorn.conf.py | ||
imei.sh | ||
nginx-serve-static.conf | ||
nginx.conf | ||
pg_hba.conf | ||
readme.md | ||
requirements.txt | ||
run_tests.py | ||
schema.sql | ||
seed-db.sql | ||
snappy_PCM.txt | ||
snappy_rDrama.txt | ||
startup.sh | ||
startup_chat.sh | ||
startup_docker.sh | ||
supervisord.conf | ||
ubuntu_setup.sh |
readme.md
This code runs https://rdrama.net, https://pcmemes.net and https://watchpeopledie.tv
Installation (Windows/Linux/MacOS)
1- Install Docker on your machine.
2- Run the following commands in the terminal:
git clone https://github.com/Aevann1/rDrama/
cd rDrama
docker-compose down --rmi all --remove-orphans --volumes
docker-compose up
3- That's it! Visit localhost
in your browser and make an account (the first account to be made will have full admin rights)
4- Optional: to change the domain from "localhost" to something else and configure the site settings, as well as integrate it with the external services the website uses, edit the variables in the env
file and then restart the docker container.