sudo: required

language: python

services:
  - docker
  - postgresql

addons:
  postgresql: "9.3"

before_script:
  - psql -c 'create database travis_ci_test;' -U postgres

before_install:
  - docker build -t impactlab/oeem-energy-datastore .
  - docker ps -a
  - docker run impactlab/oeem-energy-datastore -c "cd /code; source env.sh; python manage.py test"

script:
  - python manage.py test


sudo: required

language: python

services:
  - docker
  - postgresql

addons:
  postgresql: "9.3"

before_script:
  - psql -c 'create database travis_ci_test;' -U postgres

before_install:
  - docker build -t impactlab/oeem-energy-datastore .
  - docker ps -a
  - docker run impactlab/oeem-energy-datastore -e DATABASE_URL=$DATABASE_URL -e DJANGO_SETTINGS_MODULE=$DJANGO_SETTINGS_MODULE -e SECRET_KEY=$SECRET_KEY -e DATASTORE_ACCESS_TOKEN=$DATASTORE_ACCESS_TOKEN -e DATASTORE_URL=$DATASTORE_URL -e DJANGO_LOGFILE=$DJANGO_LOGFILE -e TEST=$TEST

script:
  - python manage.py test


Add environment variables to docker run command
Add environment variables to docker run command
