Mirror of metasploit
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

.travis.yml 2.3KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. dist: trusty
  2. sudo: false
  3. group: stable
  4. bundler_args: --without coverage development pcap
  5. cache: bundler
  6. addons:
  7. postgresql: '9.6'
  8. apt:
  9. packages:
  10. - libpcap-dev
  11. - graphviz
  12. language: ruby
  13. rvm:
  14. - '2.3.8'
  15. - '2.4.5'
  16. - '2.5.5'
  17. - '2.6.2'
  18. env:
  19. - CMD='bundle exec rake rspec-rerun:spec SPEC_OPTS="--tag content"'
  20. - CMD='bundle exec rake rspec-rerun:spec SPEC_OPTS="--tag ~content"'
  21. # Used for testing the remote data service
  22. - CMD='bundle exec rake rspec-rerun:spec SPEC_OPTS="--tag content" REMOTE_DB=1'
  23. - CMD='bundle exec rake rspec-rerun:spec SPEC_OPTS="--tag ~content" REMOTE_DB=1'
  24. matrix:
  25. fast_finish: true
  26. exclude:
  27. - rvm: '2.3.8'
  28. env: CMD='bundle exec rake rspec-rerun:spec SPEC_OPTS="--tag content" REMOTE_DB=1'
  29. - rvm: '2.4.5'
  30. env: CMD='bundle exec rake rspec-rerun:spec SPEC_OPTS="--tag content" REMOTE_DB=1'
  31. jobs:
  32. # build docker image
  33. include:
  34. - env: CMD="/usr/bin/docker-compose build" DOCKER="true"
  35. # we do not need any setup
  36. before_install: skip
  37. install: skip
  38. before_script:
  39. - curl -L https://github.com/docker/compose/releases/download/1.22.0/docker-compose-`uname -s`-`uname -m` > docker-compose
  40. - chmod +x docker-compose
  41. - sudo mv docker-compose /usr/bin
  42. before_install:
  43. - "echo 'gem: --no-ri --no-rdoc' > ~/.gemrc"
  44. - rake --version
  45. # Fail build if msftidy is not successful
  46. - ln -sf ../../tools/dev/pre-commit-hook.rb ./.git/hooks/post-merge
  47. - ls -la ./.git/hooks
  48. - ./.git/hooks/post-merge
  49. # Update the bundler
  50. - gem update --system
  51. - gem install bundler
  52. before_script:
  53. - cp config/database.yml.travis config/database.yml
  54. - bundle exec rake --version
  55. - bundle exec rake db:create
  56. - bundle exec rake db:migrate
  57. # fail build if db/schema.rb update is not committed
  58. - git diff --exit-code db/schema.rb
  59. script:
  60. - echo "${CMD}"
  61. # we need travis_wait because the Docker build job can take longer than 10 minutes
  62. #- if [[ "${DOCKER}" == "true" ]]; then echo "Starting Docker build job"; travis_wait 40 "${CMD}"; else bash -c "${CMD}"; fi
  63. # docker_wait is currently broken on travis-ci, so let's just run CMD directly for now
  64. - bash -c "${CMD}"
  65. notifications:
  66. irc: "irc.freenode.org#msfnotify"
  67. git:
  68. depth: 5
  69. # Blacklist certain branches from triggering travis builds
  70. branches:
  71. except:
  72. - gh-pages
  73. - metakitty
  74. services:
  75. - docker