Django NDR Core is a django app which helps you build a web interface to present your research data. This repository contains the sources to the ndr_core module. You are free to clone or download it, but you'll only need it if you want to develop it further (which is highly welcomed). To use NDR Core you can install it from PyPi or check out the Docker image.
- Read the Documentation on ReadTheDocs.
- Find the module on PyPi.
- Check out the Docker image on Docker Hub.
- See ndrcore.org for a demo and a list of projects using NDR Core. (in development).
First you need to install NDR Core. You can do this in different ways. You can install it from PyPi, you can use the Docker image, or you can clone this repository and install it from the sources.
It is recommended to use the docker image for local testing and configuration. For production use you should install NDR Core from PyPi and use a webserver like nginx to serve the application.
The Docker image is available on Docker Hub. You can pull it with the following command:
docker pull sorinmarti/django_ndr_core
You can run the image with the following command:
docker run -p 8000:8000 sorinmarti/django_ndr_core
This will start the application on port 8000. You can access it with your browser on http://localhost:8000.
This is a step-by-step guide to install NDR Core on a Ubuntu Machine (or similar). It is recommended to use a virtual environment for the installation. This guide assumes that you have a fresh Ubuntu installation. If you already have Python and pip installed, you can skip the first two steps.
python3 --version
pip3 --version
python3 -m pip install --upgrade pip
If installed, a version number is shown. If not, follow the next step
sudo apt-get update
sudo apt-get install python3.11
sudo apt-get -y install python3-pip
Create a directory for your project and change into it. This will be the root directory of your project. It contains the virtual environment and the django project.
mkdir <project_root>
cd <project_root>
pip3 install virtualenv
virtualenv venv
source venv/bin/activate
python -m pip install --upgrade pip
This will install all the needed dependencies and also install django.
pip install django-ndr-core
Replace <project_name>
with the name of your project. It can be the same as your project root directory.
django-admin startproject <project_name>
cd <project_name>
Open <project_name>/settings.py
and add the ndr_core module and its dependencies to INSTALLED_APPS
:
(Leave the existing settings in place).
INSTALLED_APPS = [
[...],
'ndr_core'
]
Django works as such that there are different apps. django-ndr-core is a django-app which lets you create and manage your own app. Use the following command initialize your own.
python manage.py init_ndr_core
Run your server.
python manage.py runserver
Visit http://localhost:8000/ to view your website and http://localhost:8000/ndr_core/ to access the configuration interface. The last command runs your server on port 8000. This is not suitable for production use. You should use a webserver like nginx to serve your application. See the Documentation for more information.
- Create a basic version of the module
- Create a Docker image
- Create a PyPi package
- Create a documentation
- Create a demo site
- Add more features
- Add more tests
- Add more documentation
- Add more examples
- Add more configuration options
- Add more themes
- Add more languages