diff --git a/Makefile b/Makefile index 634fc88..17bf763 100644 --- a/Makefile +++ b/Makefile @@ -12,7 +12,7 @@ dev: FLASK_APP=dev.py bin/flask run -p 8000 prod: - bin/gunicorn -c gunicorn_config.py wsgi:app + bin/gunicorn -c gunicorn_config.py production:app deploy_lambda: pipenv run pip install --target ./lambda_function/package -r lambda_function/requirements.txt diff --git a/README.md b/README.md index cf6fbc4..c0a5e0b 100644 --- a/README.md +++ b/README.md @@ -72,3 +72,28 @@ If you need to run the server with ssl cert, add these rows: certfile = "/path/to/ssl/certfile.pem" keyfile = "path/to/ssl/privkey.pem" ``` + +## certbot + +install certbot: + + > apt-get install certbot + +or on mac: + + > brew install certbot + +Make sure that you open ports on your router for letsencrypt connections: + +- local port: 4080 - public port: 80 +- local port: 4443 - public port: 443 + +Then you can generate a new certificate and chain file: + + > certbot certonly --standalone -d your_domain --http-01-port 4080 --tls-sni-01-port 4443 + +To renew cert, run: + + > certbot renew + +or re-generate certificates