This repository provides a template for deploying a Django backend served by Nginx/Gunicorn on port 8000, and a NuxtJS/Vuetify front end served by Node on port 80
- Docker: https://docs.docker.com/install/#supported-platforms
- docker-compose: https://docs.docker.com/compose/install/
- An AWS account
In an empty directory:
- Create docker machine (replace
MY_AWS_ACCESS_KEY
,MY_SECRET_KEY
andmachine_name
as appropriate)
docker-machine create -d amazonec2 --amazonec2-access-key MY_AWS_ACCESS_KEY --amazonec2-secret-key MY_SECRET_KEY machine_name
- Setup the environment
docker-machine env machine_name
- Clone this repository (or your own fork) and cd into it
git clone https://github.com/chris104957/docker-nginx-django-nuxt-template.git && cd docker-nginx-django-nuxt-template
- Build and deploy image
docker-compose build
docker-compose up -d
- Go to the AWS console and look in your EC2 running instances for the machine, open port 80, then go to the public IP to see if it worked