diff --git a/AutoTweetLiker/__pycache__/__init__.cpython-37.pyc b/AutoTweetLiker/__pycache__/__init__.cpython-37.pyc index b13ea4b..a869aea 100644 Binary files a/AutoTweetLiker/__pycache__/__init__.cpython-37.pyc and b/AutoTweetLiker/__pycache__/__init__.cpython-37.pyc differ diff --git a/AutoTweetLiker/__pycache__/settings.cpython-37.pyc b/AutoTweetLiker/__pycache__/settings.cpython-37.pyc index b3ee580..588759d 100644 Binary files a/AutoTweetLiker/__pycache__/settings.cpython-37.pyc and b/AutoTweetLiker/__pycache__/settings.cpython-37.pyc differ diff --git a/AutoTweetLiker/__pycache__/urls.cpython-37.pyc b/AutoTweetLiker/__pycache__/urls.cpython-37.pyc index 736c036..6d96e4f 100644 Binary files a/AutoTweetLiker/__pycache__/urls.cpython-37.pyc and b/AutoTweetLiker/__pycache__/urls.cpython-37.pyc differ diff --git a/AutoTweetLiker/__pycache__/wsgi.cpython-37.pyc b/AutoTweetLiker/__pycache__/wsgi.cpython-37.pyc index fae8816..8c08951 100644 Binary files a/AutoTweetLiker/__pycache__/wsgi.cpython-37.pyc and b/AutoTweetLiker/__pycache__/wsgi.cpython-37.pyc differ diff --git a/AutoTweetLiker/mysite.sqlite3 b/AutoTweetLiker/mysite.sqlite3 index 88eff2e..8efd10b 100644 Binary files a/AutoTweetLiker/mysite.sqlite3 and b/AutoTweetLiker/mysite.sqlite3 differ diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..17648e5 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,8 @@ +FROM python:3.7-alpine + +ENV PYTHONONBUFFERED 1 + +RUN mkdir /code +WORKDIR /code +COPY . /code/ +RUN pip install -r requirements.txt \ No newline at end of file diff --git a/auto_tweet_liker/__pycache__/__init__.cpython-37.pyc b/auto_tweet_liker/__pycache__/__init__.cpython-37.pyc index d2fe9b8..900bd34 100644 Binary files a/auto_tweet_liker/__pycache__/__init__.cpython-37.pyc and b/auto_tweet_liker/__pycache__/__init__.cpython-37.pyc differ diff --git a/auto_tweet_liker/__pycache__/admin.cpython-37.pyc b/auto_tweet_liker/__pycache__/admin.cpython-37.pyc index c42e35f..c9e53d4 100644 Binary files a/auto_tweet_liker/__pycache__/admin.cpython-37.pyc and b/auto_tweet_liker/__pycache__/admin.cpython-37.pyc differ diff --git a/auto_tweet_liker/__pycache__/apps.cpython-37.pyc b/auto_tweet_liker/__pycache__/apps.cpython-37.pyc index 2c10ebd..abed0bf 100644 Binary files a/auto_tweet_liker/__pycache__/apps.cpython-37.pyc and b/auto_tweet_liker/__pycache__/apps.cpython-37.pyc differ diff --git a/auto_tweet_liker/__pycache__/models.cpython-37.pyc b/auto_tweet_liker/__pycache__/models.cpython-37.pyc index c43a2e5..6f84fe7 100644 Binary files a/auto_tweet_liker/__pycache__/models.cpython-37.pyc and b/auto_tweet_liker/__pycache__/models.cpython-37.pyc differ diff --git a/auto_tweet_liker/__pycache__/urls.cpython-37.pyc b/auto_tweet_liker/__pycache__/urls.cpython-37.pyc index 1ee2a70..e4ec6e0 100644 Binary files a/auto_tweet_liker/__pycache__/urls.cpython-37.pyc and b/auto_tweet_liker/__pycache__/urls.cpython-37.pyc differ diff --git a/auto_tweet_liker/__pycache__/utils.cpython-37.pyc b/auto_tweet_liker/__pycache__/utils.cpython-37.pyc index 43247d7..cdd8f97 100644 Binary files a/auto_tweet_liker/__pycache__/utils.cpython-37.pyc and b/auto_tweet_liker/__pycache__/utils.cpython-37.pyc differ diff --git a/auto_tweet_liker/__pycache__/views.cpython-37.pyc b/auto_tweet_liker/__pycache__/views.cpython-37.pyc index b4f3b68..25baf76 100644 Binary files a/auto_tweet_liker/__pycache__/views.cpython-37.pyc and b/auto_tweet_liker/__pycache__/views.cpython-37.pyc differ diff --git a/auto_tweet_liker/migrations/__pycache__/__init__.cpython-37.pyc b/auto_tweet_liker/migrations/__pycache__/__init__.cpython-37.pyc index 3c65eec..79397c8 100644 Binary files a/auto_tweet_liker/migrations/__pycache__/__init__.cpython-37.pyc and b/auto_tweet_liker/migrations/__pycache__/__init__.cpython-37.pyc differ diff --git a/auto_tweet_liker/utils.py b/auto_tweet_liker/utils.py index 7cb7a22..c6ddefe 100644 --- a/auto_tweet_liker/utils.py +++ b/auto_tweet_liker/utils.py @@ -1,8 +1,9 @@ import tweepy +import os #Application key -CONSUMER_KEY = '' -CONSUMER_SECRET = '' +CONSUMER_KEY = os.getenv("CONS_KEY") +CONSUMER_SECRET = os.getenv("CONS_SECRET") def get_api(request): # set up and return a twitter api object diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..aef45df --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,13 @@ +version: '3' + +services: + web: + build: . + # Exporting CONSUMER KEY and CONSUMER SECRET key from tweeter api as an environment variable + command: sh -c "export CONS_KEY="" + && export CONS_SECRET="" + && python manage.py runserver 0.0.0.0:8000" + volumes: + - .:/code + ports: + - "8000:8000" \ No newline at end of file diff --git a/requirements.txt b/requirements.txt index 0439ef2..ebbef27 100644 Binary files a/requirements.txt and b/requirements.txt differ