.gitlab-ci.yml 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. default:
  2. image: $CI_REGISTRY/docker/zammad-ci:3.0.4
  3. include:
  4. - local: '/.gitlab/ci/base.yml'
  5. - local: '/.gitlab/ci/pre.yml'
  6. - local: '/.gitlab/ci/integration.yml'
  7. - local: '/.gitlab/ci/rspec.yml'
  8. - local: '/.gitlab/ci/vitest.yml'
  9. - local: '/.gitlab/ci/cypress.yml'
  10. - local: '/.gitlab/ci/unit.yml'
  11. - local: '/.gitlab/ci/browser-core.yml'
  12. - local: '/.gitlab/ci/browser-integration.yml'
  13. # Stages
  14. stages:
  15. - pre
  16. - test
  17. - browser-core
  18. - browser-integration
  19. # Global variables added to the ENV of each job
  20. variables:
  21. # for faster translation loading
  22. Z_LOCALES: "en-us:de-de"
  23. # Browser tests and variables
  24. RAILS_SERVE_STATIC_FILES: "true"
  25. TZ: "Europe/London"
  26. # docker-imap-devel variables required for browser tests
  27. MAILNAME: "mail.test.dc.zammad.com"
  28. MAILBOX_INIT: "zammad@mail.test.dc.zammad.com:zammad"
  29. MAIL_ADDRESS: "zammad@mail.test.dc.zammad.com"
  30. MAIL_PASS: "zammad"
  31. # docker-imap-devel variables required for integration tests
  32. MAIL_SERVER: "mail"
  33. MAIL_SERVER_ACCOUNT: "zammad@mail.test.dc.zammad.com:zammad"
  34. MAIL_SERVER_EMAIL: "zammad@mail.test.dc.zammad.com"
  35. KEEP_ON_MAIL_SERVER: "mail"
  36. KEEP_ON_MAIL_SERVER_ACCOUNT: "zammad@mail.test.dc.zammad.com:zammad"
  37. # Temporary switch to enable the mobile front end for testing.
  38. ENABLE_EXPERIMENTAL_MOBILE_FRONTEND: 'true'
  39. # Compile assets only once.
  40. CI_SKIP_ASSETS_PRECOMPILE: 'true'
  41. cache:
  42. # Cache gems in between jobs and pipelines
  43. - key:
  44. files:
  45. - Gemfile.lock
  46. paths:
  47. - vendor/ruby
  48. - fresh.env
  49. # Cache node_modules likewise
  50. - key:
  51. files:
  52. - yarn.lock
  53. paths:
  54. - .yarn/cache
  55. # Initialize application env
  56. before_script:
  57. - source /etc/profile.d/rvm.sh
  58. - echo -e "\\e[0Ksection_start:`date +%s`:bundle_install[collapsed=true]\\r\\e[0Kbundle install"
  59. - bundle config set --local frozen 'true'
  60. - bundle config set --local path 'vendor'
  61. - bundle install -j $(nproc)
  62. - echo -e "\\e[0Ksection_end:`date +%s`:bundle_install\\r\\e[0K"
  63. - bundle exec ruby .gitlab/configure_environment.rb
  64. - source .gitlab/environment.env
  65. after_script:
  66. - .gitlab/environment_info.sh > log/environment_info.log
  67. # Copy logs from other containers to store them as artifacts.
  68. - cp /builds/*.log log/ || true