.gitlab-ci.yml 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  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. # Cache gems in between jobs and pipelines
  40. # ATTENTION: We use a combination of the Ruby major and minor version number
  41. # as a key for the cache to avoid cache growth and incompatibilities between
  42. # the gems. Search hook: 3.0.4 (change it when updating the Ruby version too)
  43. cache:
  44. key: "centos7ruby304"
  45. paths:
  46. - vendor/ruby
  47. # ATTENTION: This should be a dedicated cache only used in the job "TODO".
  48. # ATTENTION: Remember to update the global CI ENV setting with the latest
  49. # version of the ENV from an artifact of the "TODO" job to use a valid key.
  50. # A dedicated cache should be used because the ENVs are not bound to the Ruby version and OS.
  51. # Unfortunately GitLab is not yet capable of having multiple cache-s per job
  52. # See: https://gitlab.com/gitlab-org/gitlab/-/issues/32814
  53. - fresh.env
  54. # Initialize application env
  55. before_script:
  56. - source /etc/profile.d/rvm.sh
  57. - echo -e "\\e[0Ksection_start:`date +%s`:bundle_install[collapsed=true]\\r\\e[0Kbundle install"
  58. - bundle config set --local frozen 'true'
  59. - bundle config set --local path 'vendor'
  60. - bundle install -j $(nproc)
  61. - echo -e "\\e[0Ksection_end:`date +%s`:bundle_install\\r\\e[0K"
  62. - bundle exec ruby .gitlab/configure_environment.rb
  63. - source .gitlab/environment.env
  64. after_script:
  65. - .gitlab/environment_info.sh > log/environment_info.log