forked from vertica/vertica-sql-go
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
34 lines (29 loc) · 1.86 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
language: go
os:
- linux
go:
- 1.11.x
- 1.12.x
- master
go_import_path: github.com/vertica/vertica-sql-go
before_install:
- git clone https://github.com/jbfavre/docker-vertica.git
- curl $VERTICA_CE_URL --create-dirs -o docker-vertica/packages/vertica-ce.latest.rpm
- docker build -f docker-vertica/Dockerfile.centos.7_9.x --build-arg VERTICA_PACKAGE=vertica-ce.latest.rpm -t jbfavre/vertica docker-vertica
- docker images
- docker run --hostname vertica-docker --name vertica_docker -d -p 5433:5433 jbfavre/vertica
- sleep 60
script:
- go test -race . -args --locator localhost:5433 --user dbadmin
- go test -race . -args --locator localhost:5433 --user dbadmin --use_prepared_statements=0
- go test -race ./logger
- docker exec -u dbadmin vertica_docker /opt/vertica/bin/vsql -c "SELECT SET_CONFIG_PARAMETER('SSLPrivateKey', '`cat ./resources/tests/ssl/root.key`');"
- docker exec -u dbadmin vertica_docker /opt/vertica/bin/vsql -c "SELECT SET_CONFIG_PARAMETER('SSLCertificate', '`cat ./resources/tests/ssl/root.crt`');"
# docker exec -u dbadmin vertica_docker /opt/vertica/bin/vsql -c "ALTER DATABASE docker SET SSLCA='`cat ./resources/tests/ssl/root.crt`';"
- docker exec -u dbadmin vertica_docker /opt/vertica/bin/vsql -c "ALTER DATABASE docker SET EnableSSL=1;"
- docker exec -u dbadmin vertica_docker /opt/vertica/bin/admintools --tool stop_db --database docker
- docker exec -u dbadmin vertica_docker /opt/vertica/bin/admintools --tool start_db --database docker
- go test -race . -args --locator localhost:5433 --user dbadmin --tlsmode=server
- go test -race . -args --locator localhost:5433 --user dbadmin --tlsmode=server --use_prepared_statements=0
# go test --locator localhost:5433 --user dbadmin --tlsmode=server-strict -race .
# go test --locator localhost:5433 --user dbadmin --tlsmode=server-strict --use_prepared_statements=0 -race .