add docker file to the example project

This commit is contained in:
dmlb2000 2016-01-23 17:04:34 -08:00
parent 412687216c
commit ae42c4cf34
2 changed files with 20 additions and 0 deletions

View file

@ -0,0 +1,6 @@
FROM python:2-onbuild
RUN [ "python", "manage.py", "migrate" ]
RUN [ "python", "manage.py", "creatersakey" ]
EXPOSE 8000
CMD [ "python", "manage.py", "runserver", "0.0.0.0:8000" ]

View file

@ -29,6 +29,20 @@ $ python manage.py runserver
Open your browser and go to `http://localhost:8000`. Voilà!
## Or Use Docker
Build the container first.
```
docker build -t django-oidc-provider .
```
Run the container next.
```
docker run -d -p 8000:8000 django-oidc-provider
```
Open your browser and go to `http://localhost:8000`. Voilà!
## Install package for development
After you run `pip install -r requirements.txt`.