Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

README.md

Tracing the Django Tutorial

Example web application based on:

Datadog APM is enabled following the documentation:

# mysite/mysite/settings.py

INSTALLED_APPS = [
    ...
    'ddtrace.contrib.django',
]

DATADOG_TRACE = {
    'DEFAULT_SERVICE': 'django-tutorial-docker',
    'TAGS': {'env': 'dev'},
    'AGENT_HOSTNAME': 'agent',
    'ENABLED': True,
    'DEBUG': True,
}

Setup

Start the Docker containers and web server:

DD_API_KEY=... docker-compose up --build -d

Run migration scripts to set up the database:

docker-compose exec app python manage.py makemigrations
docker-compose exec app python manage.py migrate

Create an admin user:

docker-compose exec app python manage.py createsuperuser
# Enter username, email, password