1
0

.travis.yml 845 B

1234567891011121314151617181920212223242526272829303132333435
  1. sudo: required
  2. language: go
  3. arch:
  4. - amd64
  5. - arm64
  6. go:
  7. - "1.15"
  8. env:
  9. - DB_USER=root DB_PASSWORD=test123456 DB_HOST=127.0.0.1 DB_PORT=13306 REDIS_HOST=127.0.0.1 REDIS_PORT=16379 API_PORT=18080 API_HOST=127.0.0.1
  10. services:
  11. - docker
  12. before_install:
  13. - tmpdaemon=$(mktemp)
  14. - sudo jq '."registry-mirrors" += ["https://mirror.gcr.io"]' /etc/docker/daemon.json > $tmpdaemon
  15. - sudo mv $tmpdaemon /etc/docker/daemon.json
  16. - sudo systemctl daemon-reload
  17. - sudo systemctl restart docker
  18. - docker system info
  19. script:
  20. - go get -u github.com/go-sql-driver/mysql
  21. - make fmt
  22. - make fmt-check
  23. - make misspell-check
  24. - make all
  25. - bash ./docker_test.sh
  26. after_success:
  27. - go test -race -coverprofile=coverage.txt -covermode=atomic github.com/open-falcon/falcon-plus/modules/api/test
  28. - bash <(curl -s https://codecov.io/bash)