From 9c184ee05ddb664e27973e0c124e4153d5bd814e Mon Sep 17 00:00:00 2001 From: Oleg Silkin Date: Mon, 22 Jul 2019 08:16:14 -0400 Subject: [PATCH] Removes unnecessary junk --- compile.py | 17 ----------------- config/nginx.conf | 27 --------------------------- requirements.txt | 31 ------------------------------- src/data.conf | 17 ----------------- 4 files changed, 92 deletions(-) delete mode 100644 compile.py delete mode 100644 config/nginx.conf delete mode 100644 src/data.conf diff --git a/compile.py b/compile.py deleted file mode 100644 index 672e97a..0000000 --- a/compile.py +++ /dev/null @@ -1,17 +0,0 @@ -from distutils.core import setup -from distutils.extension import Extension -from Cython.Distutils import build_ext -from Cython.Build import cythonize - -ext_modules = [ - Extension("src.database", ["src/database.py"]), - Extension("src.settings", ["src/settings.py"]), - Extension("src.writes", ["src/writes.py"]), - Extension("schema.db_helpers", ["schema/db_helpers.py"]), -] # might need to add some external imports here too - -setup( - name="comment_server", - cmdclass={"build_ext": build_ext}, - ext_modules=cythonize(ext_modules, compiler_directives={'language_level': '3'}) -) diff --git a/config/nginx.conf b/config/nginx.conf deleted file mode 100644 index 0c82c89..0000000 --- a/config/nginx.conf +++ /dev/null @@ -1,27 +0,0 @@ -worker_processes 1; -daemon off; -error_log /dev/stdout warn; - -events { - worker_connections 1024; - accept_mutex off; -} - -http { - default_type application/json; - access_log off; - - server { - listen 5921; - location /api { - proxy_set_header HOST $host; - proxy_set_header X-Forwarded-Proto $scheme; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - - proxy_redirect off; - proxy_pass http://localhost:2903; - - } - } -} diff --git a/requirements.txt b/requirements.txt index ec59847..1290854 100644 --- a/requirements.txt +++ b/requirements.txt @@ -8,34 +8,3 @@ aiosqlite==0.10.0 PyNaCl>=1.3.0 requests cython - -{ - "items": [ - { - "comment": "Sick chess set", - "comment_id": "a1336c28a0752d6695d6588330842e8d43f4f89839193a0fe09b3eb8dee0588d", - "timestamp": 1561669743 - }, - { - "channel_id": "6d266af6c25c80fa2ac6cc7662921ad2e90a07e8", - "channel_name": "@bbbbb", - "channel_url": "lbry://@bbbbb#6d266af6c25c80fa2ac6cc7662921ad2e90a07e8", - "comment": "YOLO", - "comment_id": "676266d2a750a206cf279ff777a21e2914acb33b820cef9ea8479afb3d926d58", - "is_channel_signature_valid": true, - "signature": "e8ad5dbc268365e5d16f6a9b5d82323efc550412a7a291aa3e715e31641cc57b18241a132ebed28a848086fca6e200a735281c631c7474b01b4c32851ea3dd57", - "signing_ts": "1561669614", - "timestamp": 1561669614 - } - ], - "page": 1, - "page_size": 50, - "total_items": 2, - "total_pages": 1 -} - -pieces = [ - comment['signing_ts'].encode(), - channel.claim_hash, - comment['comment'].encode() - ] \ No newline at end of file diff --git a/src/data.conf b/src/data.conf deleted file mode 100644 index baeb5b4..0000000 --- a/src/data.conf +++ /dev/null @@ -1,17 +0,0 @@ -location / { - limit_except GET HEAD { - deny all; - } -} - -location /api/ { - limit_except GET HEAD { - deny all; - } -} - -location /api { - limit_except GET HEAD POST { - - } -} \ No newline at end of file