forked from buildlyio/buildly-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
56 lines (56 loc) · 2.37 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
language: python
cache: pip
dist: xenial
python:
- "3.7"
services:
- docker
- postgresql
addons:
postgresql: "9.6"
before_script:
- sleep 10
- docker run -p 389:389 -p 636:636 --name openldap_server -d osixia/openldap:1.3.0
- psql -c 'create database buildly_api;' -U postgres
- sudo touch /var/log/buildly.log
- sudo chown travis /var/log/buildly.log
install:
- cat requirements/base.txt | grep "^Django==\|^psycopg2" | xargs pip install
- pip install -r requirements/ci.txt
script:
- flake8
- bandit -r . -ll
- pytest --cov-config=.coveragerc --cache-clear
- docker build -t $DOCKER_REPO .
env:
global:
ALLOWED_HOSTS: "*"
CORS_ORIGIN_WHITELIST: "*"
DATABASE_ENGINE: "postgresql"
DATABASE_NAME: "buildly_api"
DATABASE_USER: "postgres"
DATABASE_PASSWORD: ""
DATABASE_HOST: "localhost"
DATABASE_PORT: "5432"
DEFAULT_ORG: "Default Organization"
DJANGO_SETTINGS_MODULE: "buildly.settings.production"
SOCIAL_AUTH_GITHUB_REDIRECT_URL: "/complete/github"
SOCIAL_AUTH_GOOGLE_OAUTH2_REDIRECT_URL: "/complete/google-oauth2"
SOCIAL_AUTH_MICROSOFT_GRAPH_REDIRECT_URL: "/complete/microsoft-graph"
JWT_ISSUER: "buildly"
JWT_PRIVATE_KEY_RSA_BUILDLY: $'-----BEGIN RSA PRIVATE KEY-----\nMIIBOwIBAAJBALFc9NFZaOaSwUMPNektbtJqEjYZ6IRBqhqvJu1hKPYn9HYd75c0\ngIDYHJ9lb7QwQvg44aO27104rDK0xSstzL0CAwEAAQJAe5z5096oyeqGX6J+RGGx\n11yuDJ7J+0N4tthUHSWWUtgkd19NvmTM/mVLmPCzZHgNUT+aWUKsQ84+jhru/NQD\n0QIhAOHOzFmjxjTAR1jspn6YtJBKQB40tvT6WEvm2mKm0aD7AiEAyRPwXyZf3JT+\nM6Ui0Mubs7Qb/E4g1d/kVL+o/XoZC6cCIQC+nKzPtnooKW+Q1yOslgdGDgeV9/XB\nUlqap+MNh7hJZQIgZNaM+wqhlFtbx8aO2SrioJI4XqVHrjojpaSgOM3cdY0CIQDB\nQ6ckOaDV937acmWuiZhxuG2euNLwNbMldtCV5ADo/g==\n-----END RSA PRIVATE KEY-----'
JWT_PUBLIC_KEY_RSA_BUILDLY: $'-----BEGIN PUBLIC KEY-----\nMFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBALFc9NFZaOaSwUMPNektbtJqEjYZ6IRB\nqhqvJu1hKPYn9HYd75c0gIDYHJ9lb7QwQvg44aO27104rDK0xSstzL0CAwEAAQ==\n-----END PUBLIC KEY-----'
SECRET_KEY: "nothing"
OAUTH_CLIENT_ID: "vBn4KsOCthm7TWzMH0kVV0dXkUPJEtOQwaLu0eoC"
OAUTH_CLIENT_SECRET: "0aYDOHUNAxK4MjbnYOHhfrKx8EzjKqN6GbB6IGyCgpT6pmQ5pEVJmH7mIEUJ"
DOCKER_REPO: "buildly/buildly"
LDAP_ENABLE: "True"
LDAP_HOST: "ldap://localhost:389"
LDAP_USERNAME: "cn=admin,dc=example,dc=org"
LDAP_PASSWORD: "admin"
LDAP_BASE_DN: "dc=example,dc=org"
deploy:
provider: script
script: bash scripts/deploy.sh
on:
branch: master