Skip to main content

A sample and measurement metadata database

Project description


SampleDB is a web-based sample and measurement metadata database.


You can find the documentation for the current release at

Getting Started

We recommend using our pre-built Docker images for setting up SampleDB. You will need two containers, one for a PostgreSQL database and another for SampleDB itself, and a directory to store all files in. If you would like to set up a development version of SampleDB instead, please see the contribution guide.

First, start your database container:

docker run \
    -d \
    -e PGDATA=/var/lib/postgresql/data/pgdata \
    -v `pwd`/pgdata:/var/lib/postgresql/data/pgdata:rw \
    --restart=always \
    --name sampledb-postgres \

Next, start the SampleDB container:

docker run \
    -d \
    --link sampledb-postgres \
    -e \
    -e \
    -e \
    -e SAMPLEDB_SQLALCHEMY_DATABASE_URI=postgresql+psycopg2://postgres:@sampledb-postgres:5432/postgres \
    -e SAMPLEDB_FILE_STORAGE_PATH=/home/sampledb/files/ \
    -v `pwd`/files:/home/sampledb/files:rw \
    --restart=always \
    --name sampledb \
    -p 8000:8000 \

This will start a basic SampleDB instance at http://localhost:8000.

To use the administration scripts, run:

docker exec sampledb env/bin/python -m sampledb help

and replace help with the script you want to run.

Next steps:

  • You can set additional configuration environment variables to customize or enable some features, including LDAP authentication and JupyterHub integration. You should at least configure a valid mail server, sender and contact email.

  • You can use the administration scripts to create instruments, actions and bot users for use with the WebAPI.

  • If you wish to run SampleDB in production, please ensure that you make backups of your database and the file directory, and ensure that your server stays secure. We strongly recommend placing SampleDB behind an nginx reverse proxy for TLS termination.

  • To update an existing SampleDB instance, please create a full backup and then start the SampleDB container using the new image.


If you want to improve SampleDB, please read the contribution guide for a few notes on how to report issues or submit changes.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sampledb-0.10.0.tar.gz (1.7 MB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page