Files
web2.0-backend/.gitlab-ci.yml
T
2017-05-21 16:28:47 +03:00

40 lines
844 B
YAML

image: python:3.5
services:
- postgres:latest
variables:
POSTGRES_DB: ci
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
stages:
- test
- lint
test:
stage: test
variables:
DATABASE_URL: "postgresql://postgres:postgres@postgres:5432/$POSTGRES_DB"
script:
- python -V
- pip install -r requirements.txt
- cp sikweb/settings-sample.py sikweb/default_settings.py
- cp sikweb/.ci-settings.py sikweb/settings.py
- python manage.py migrate --noinput
- python manage.py createdefaultadmin
- python manage.py test
pep8:
stage: lint
script:
- pip install -r requirements.txt
- pep8 --config=setup.cfg --count .
eslint:
image: node:7.10.0
stage: lint
script:
- npm install -g eslint
- eslint .