I’m having issue getting postgres to work on my django project in GitLab CI.
I’m follwing this documentation -
http://docs.gitlab.com/ce/ci/examples/test-and-deploy-python-application-to-heroku.html .
I’ve set the DATABASE_URL=postgres://postgres:@postgres:5432/test_db
as per the guide but still I’m getting following error in the build - could not translate host name "postgres" to address: Name or service not known
This is my gitlab-ci.yml -
test:
script:
- export DATABASE_URL=postgres://postgres:@postgres:5432/test_db
- apt-get update -y
- apt-get install -y python-dev python-pip
- pip install -r requirements.txt
- python manage.py test
This is on Gitlab.com. Am I doing something wrong?