Code Repo of the IAD's web-app.
- Download or Clone this repo
- Adapt the information in
webpage/metadata.py
according to your needs. - Create an virtual environment and run
pip install -r requirements.txt
This projects uses modularized settings (to keep sensitive information out of version control or being able to use the same code for development and production). Therefore you'll have to append all manage.py
commands with a --settings
parameter pointing to the settings file you'd like to run the code with. For development just append --settings={nameOfYouProject}.settings.dev
to the following commands, e.g. python manage.py makemigrations --settings=iad.settings.dev
- Run
makemigrations
,migrate
, andrunserver
and check http://127.0.0.1:8000/
To get needed software you can run
pip install -r requirements_test.txt
To run the tests execute
python manage.py test --settings=iad.settings.test
This application uses PostgreSQL with the PostGIS extension to support spatial queries.
The application layer is implemented with the Python based web framework Django. GIS related functionality (see here for a detailed overview of those functions) are realized by with GeoDjango. Please refer to GeoDjangos Documentation to learn about needed requirements to run GeoDjango. The application is mainly run server-side although the data is accessible through an REST-API implemented with Django REST framework.
The presentation of GIS-related data on the client side (web-browser) is realized with Leaflet which processes the data serialized by the backend into GeoJSON though data from different sources (e.g. raster images, served following the WMS protocol ) can be integrated as well.
docker build -t iad:latest .
docker build -t iad:latest --no-cache .
To run the image you should provide an env.default
file to pass in needed environment variables; see example env.default
in this repo:
docker run -it -p 8020:8020 --rm --env-file env.default iad:latest
docker run -it -p 8020:8020 --rm --env-file env.default acdhch/iad:latest