forked from Kononnable/typeorm-model-generator
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
52 lines (52 loc) · 1.92 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
language: node_js
node_js:
- 15
- 14
- 12
- 10
cache: npm
branches:
except:
- no-engines
services:
- docker
env:
jobs:
- POSTGRES_Skip=0 POSTGRES_Host=localhost POSTGRES_Port=5432 POSTGRES_Username=test
POSTGRES_Password=test POSTGRES_Database=test POSTGRES_SSL=0 MYSQL_Skip=0
MYSQL_Host=localhost MYSQL_Port=3306 MYSQL_Username=root MYSQL_Password=admin
MYSQL_Database=test MYSQL_SSL=0 MARIADB_Skip=0 MARIADB_Host=localhost MARIADB_Port=3307
MARIADB_Username=root MARIADB_Password=admin MARIADB_Database=test MARIADB_SSL=0
MSSQL_Skip=0 MSSQL_Host=localhost MSSQL_Port=1433 MSSQL_Username=sa MSSQL_Password=Admin12345
MSSQL_Database=typeorm_mg MSSQL_SSL=0
ORACLE_Skip=0
ORACLE_Host=localhost
ORACLE_Port=1521
ORACLE_SSL=0
ORACLE_UsernameSys=sys
ORACLE_PasswordSys=Oradoc_db1
ORACLE_Database=orclpdb1.localdomain
ORACLE_Username=typeorm_mg
ORACLE_Password=Passw0rd
SQLITE_Skip=0
SQLITE_Database=/tmp/sqlitedb.db
before_install:
- sudo service mysql stop
- sudo service postgresql stop
- images=(mysql mariadb postgres mssql)
- if [ -z "$DOCKER_USERNAME" ]; then echo "DOCKER_USERNAME is unset"; else echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin; fi
- if [ -z "$DOCKER_USERNAME" ]; then export ORACLE_Skip=1; else images=(${images[@]} oracle oracle_client); fi
- if [ -n "$DOCKER_USERNAME" ]; then docker-compose up -d ${images[@]}; fi
- echo ${images[@]}
- docker-compose pull --ignore-pull-failures ${images[@]}
- docker-compose up -d ${images[@]}
before_script:
- if [ -n "$DOCKER_USERNAME" ]; then mkdir /opt/oracle; npm i oracledb --no-save; docker cp typeorm-mg-oracle-client:/usr/lib/oracle/12.2/client64/lib /opt/oracle/instantclient_12_2; fi
- export LD_LIBRARY_PATH=/opt/oracle/instantclient_12_2:$LD_LIBRARY_PATH
script:
- travis_retry sh -c 'sleep 90 && npm t -- --colors'
after_success:
- codecov
after_failure:
- docker-compose logs
- docker ps