-
Verify needed files & settings
#PROJ_ROOT/Procfile web: gunicorn <myproj>.wsgi #PROJ_ROOT/requirements.txt dj-database-url==0.4.1 Django==1.10.3 gunicorn==19.6.0 psycopg2==2.6.2 whitenoise==3.2.2 #PROJ_ROOT/runtime.txt python-3.5.2 #PROJ_ROOT/<myproj>/settings.py INSTALLED_APPS = [ ... 'gunicorn', ... ] MIDDLWARE = [ ... 'whitenoise.middleware.WhiteNoiseMiddlware', ... ] DATABASES = {'default': dj_database_url.config(), }
-
Install PostgreSQL plugin, create database container
sudo dokku plugin:install https://github.com/dokku/dokku-postgres.git postgres dokku postgres:create <myproj>
-
Create web application & link the database container
dokku apps:create <myproj> dokku postgres:link <myproj> <myproj>
-
Push our application
git remote:add dokku dokku@<mydomain.com>:<myproj> git push dokku master
-
HTTPS via Let's Encrypt
sudo dokku plugin:install https://github.com/dokku/dokku-letsencrypt.git dokku letsencrypt <myproj>
-
Enjoy!
https://<myproj>.<mydomain.com>
Created
March 13, 2017 03:21
-
-
Save dacodekid/8f7931fb835f6e43a82936cffb862efc to your computer and use it in GitHub Desktop.
Starting up with Dokku, Django, Let's Encrypt and PostgreSQL on Python 3.5.2
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment