Advertisement
Guest User

Untitled

a guest
Jan 20th, 2017
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. image: "my-rvm-npm-image"
  2.  
  3. services:
  4. - postgres:9.3-alpine
  5.  
  6. variables:
  7. POSTGRES_DB: db
  8. POSTGRES_USER: user
  9. POSTGRES_PASSWORD:
  10.  
  11. cache:
  12. untracked: true
  13. key: "$CI_BUILD_REF_NAME"
  14. paths:
  15. - node_modules/
  16.  
  17. stages:
  18. - build
  19. - rspec
  20. - npm
  21.  
  22. build:
  23. stage: build
  24. script:
  25. - sudo chown -R $(whoami) /cache
  26. - /bin/bash -l -c "rvm install $(cat .ruby-version)
  27. && rvm use $(cat .ruby-version)
  28. && gem install bundle && bundle install --jobs $(nproc) --path /cache
  29. && source ~/.nvm/nvm.sh && nvm install && npm install npm -g && npm install
  30. && bundle exec rake db:test:prepare"
  31.  
  32. rspec:
  33. stage: rspec
  34. script:
  35. - bundle exec rake
  36. npm:
  37. stage: npm
  38. script:
  39. - npm test
  40.  
  41. [[runners]]
  42. name = "xxxx"
  43. url = "URLabc.com"
  44. token = "myprojectoken"
  45. executor = "docker"
  46. [runners.docker]
  47. tls_verify = false
  48. image = "my-rvm-npm-image"
  49. privileged = true
  50. disable_cache = false
  51. volumes = ["/home/ci/cache:/cache", "/home/ci/builds:/builds"]
  52. [runners.cache]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement