Add docker dev instructions

This commit is contained in:
David Taylor
2019-07-14 23:04:12 +01:00
parent b269069b6a
commit c0fe176495
2 changed files with 19 additions and 0 deletions

12
Dockerfile Normal file
View File

@@ -0,0 +1,12 @@
FROM python:3.6
WORKDIR /app
ADD . /app
RUN pip install -r requirements.txt && \
python manage.py collectstatic --noinput
EXPOSE 8000
CMD ["python", "manage.py", "runserver", "0.0.0.0:8000"]

View File

@@ -77,6 +77,13 @@ python manage.py runserver
``` ```
Please refer to Django documentation for a full list of options available here. Please refer to Django documentation for a full list of options available here.
### Development using docker
```
docker build . -t pyrigs
docker run -it --rm -p=8000:8000 -v $(pwd):/app pyrigs
```
### Sample Data ### ### Sample Data ###
Sample data is available to aid local development and user acceptance testing. To load this data into your local database, first ensure the database is empty: Sample data is available to aid local development and user acceptance testing. To load this data into your local database, first ensure the database is empty:
``` ```