gitlab-qa 14.9.0 → 14.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. checksums.yaml +4 -4
  2. data/.gitlab-ci.yml +3 -5
  3. data/.rubocop_todo.yml +0 -1
  4. data/Gemfile.lock +13 -13
  5. data/docs/what_tests_can_be_run.md +5 -21
  6. data/gitlab-qa.gemspec +1 -1
  7. data/lib/gitlab/qa/component/base.rb +20 -10
  8. data/lib/gitlab/qa/component/chaos.rb +1 -1
  9. data/lib/gitlab/qa/component/gitaly.rb +2 -1
  10. data/lib/gitlab/qa/component/gitaly_cluster.rb +1 -1
  11. data/lib/gitlab/qa/runner.rb +0 -13
  12. data/lib/gitlab/qa/runtime/env.rb +130 -120
  13. data/lib/gitlab/qa/runtime/omnibus_configurations/object_storage.rb +1 -1
  14. data/lib/gitlab/qa/scenario/test/instance/airgapped.rb +2 -2
  15. data/lib/gitlab/qa/scenario/test/instance/image.rb +1 -1
  16. data/lib/gitlab/qa/scenario/test/instance/relative_url.rb +1 -1
  17. data/lib/gitlab/qa/scenario/test/instance/repository_storage.rb +2 -2
  18. data/lib/gitlab/qa/scenario/test/integration/ai_gateway_base.rb +2 -1
  19. data/lib/gitlab/qa/scenario/test/integration/client_ssl.rb +1 -1
  20. data/lib/gitlab/qa/scenario/test/integration/elasticsearch.rb +2 -2
  21. data/lib/gitlab/qa/scenario/test/integration/gitlab_pages.rb +1 -1
  22. data/lib/gitlab/qa/scenario/test/integration/import.rb +1 -1
  23. data/lib/gitlab/qa/scenario/test/integration/integrations.rb +2 -2
  24. data/lib/gitlab/qa/scenario/test/integration/jira.rb +2 -2
  25. data/lib/gitlab/qa/scenario/test/integration/ldap.rb +3 -3
  26. data/lib/gitlab/qa/scenario/test/integration/mattermost.rb +1 -1
  27. data/lib/gitlab/qa/scenario/test/integration/metrics.rb +1 -1
  28. data/lib/gitlab/qa/scenario/test/integration/mtls.rb +1 -1
  29. data/lib/gitlab/qa/scenario/test/integration/opensearch.rb +2 -2
  30. data/lib/gitlab/qa/scenario/test/integration/registry.rb +1 -1
  31. data/lib/gitlab/qa/scenario/test/integration/registry_tls.rb +1 -1
  32. data/lib/gitlab/qa/scenario/test/integration/registry_with_cdn.rb +2 -2
  33. data/lib/gitlab/qa/scenario/test/integration/saml.rb +3 -3
  34. data/lib/gitlab/qa/scenario/test/integration/service_ping_disabled.rb +1 -1
  35. data/lib/gitlab/qa/scenario/test/integration/smtp.rb +1 -1
  36. data/lib/gitlab/qa/scenario/test/integration/suggested_reviewer.rb +1 -1
  37. data/lib/gitlab/qa/scenario/test/omnibus/update_from_previous.rb +1 -1
  38. data/lib/gitlab/qa/support/gitlab_upgrade_path.rb +2 -2
  39. data/lib/gitlab/qa/version.rb +1 -1
  40. data/rubocop/cop/gitlab/dangerous_interpolation.rb +0 -1
  41. metadata +4 -7
  42. data/lib/gitlab/qa/component/telegraf.rb +0 -175
  43. data/lib/gitlab/qa/scenario/test/instance/staging_geo.rb +0 -32
  44. data/lib/gitlab/qa/scenario/test/sanity/version.rb +0 -93
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 07bcf4d830b0b1a566f938d304e7fca8060314fe8ec2880a0203a758fc50c366
4
- data.tar.gz: 9c20f4c1f1c9b234f8fcc4db0f5a38527f2ca6848585bd0f218195841f7cb090
3
+ metadata.gz: 0f1cb43d060925e3dd20830d8412563a94fca6fb8ad0636de7da5176b984c4e5
4
+ data.tar.gz: c6096e3712816f0c5667208d219f7e25ce125a869dc4c8b689e89e7c8c85242e
5
5
  SHA512:
6
- metadata.gz: 00051bcdf47a11a19a2b106332acca427acf2c824b098bae1d5227927d88b50f5453e520033d3448e8ba2a914fdd04f34af931f19cc31e136c6d4a8bbcf334f8
7
- data.tar.gz: deaf4242a1a8f543d2414c750e4f610b2e9c6e624b6bfea7a421b0946afab810a8b27bdd518e43fdf9be52f5946e1932d25544e942efc19ae7c64cc827b74074
6
+ metadata.gz: 526945385fb2c815c5cc5b7d17b7327523f099f0f08d123185041cde9142231664c62d253b96ae5262dc9519420cf79aa924750313e07af2c822c1bae528509d
7
+ data.tar.gz: 2782d95be4f96c1a67a1696b96bb0e8cdaa84fc0a273ac671c39925615b884c6f7e2645df4a3e95d5e74b812e82ad00af0a0a741bf4d144536764fa1d5b16a60
data/.gitlab-ci.yml CHANGED
@@ -10,7 +10,7 @@
10
10
  include:
11
11
  - component: gitlab.com/gitlab-org/components/danger-review/danger-review@~latest
12
12
  inputs:
13
- job_image: "${CI_REGISTRY}/gitlab-org/gitlab-build-images/debian-${DEBIAN_VERSION}-ruby-${RUBY_VERSION}:bundler-${BUNDLER_VERSION}"
13
+ job_image: "${CI_REGISTRY}/gitlab-org/gitlab-build-images/debian-${DEBIAN_VERSION}-ruby-${RUBY_VERSION}"
14
14
  - component: gitlab.com/gitlab-org/components/gem-release/gem-release@~latest
15
15
 
16
16
  stages:
@@ -20,7 +20,7 @@ stages:
20
20
  - deploy
21
21
 
22
22
  default:
23
- image: ${CI_REGISTRY}/gitlab-org/gitlab-build-images/debian-${DEBIAN_VERSION}-ruby-${RUBY_VERSION}:bundler-${BUNDLER_VERSION}
23
+ image: ${CI_REGISTRY}/gitlab-org/gitlab-build-images/debian-${DEBIAN_VERSION}-ruby-${RUBY_VERSION}
24
24
  tags:
25
25
  - gitlab-org
26
26
  cache:
@@ -43,8 +43,7 @@ workflow:
43
43
  variables:
44
44
  DEBIAN_VERSION: bookworm
45
45
  DOCKER_VERSION: "24.0.5"
46
- BUNDLER_VERSION: "2.5"
47
- RUBY_VERSION: "3.1"
46
+ RUBY_VERSION: "3.1.5"
48
47
  BUNDLE_PATH: vendor
49
48
  BUNDLE_SILENCE_ROOT_WARNING: "true"
50
49
  BUNDLE_SUPPRESS_INSTALL_USING_MESSAGES: "true"
@@ -145,7 +144,6 @@ package-and-test:
145
144
  - RUBY_VERSION
146
145
  - DEBIAN_VERSION
147
146
  - DOCKER_VERSION
148
- - BUNDLER_VERSION
149
147
  trigger:
150
148
  strategy: depend
151
149
  forward:
data/.rubocop_todo.yml CHANGED
@@ -55,7 +55,6 @@ Metrics/AbcSize:
55
55
  - 'lib/gitlab/qa/scenario/test/integration/registry_with_cdn.rb'
56
56
  - 'lib/gitlab/qa/scenario/test/integration/smtp.rb'
57
57
  - 'lib/gitlab/qa/scenario/test/integration/suggested_reviewer.rb'
58
- - 'lib/gitlab/qa/scenario/test/sanity/version.rb'
59
58
 
60
59
  # Offense count: 2
61
60
  # Configuration parameters: CheckIdentifiers, CheckConstants, CheckVariables, CheckStrings, CheckSymbols, CheckComments, CheckFilepaths, FlaggedTerms.
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- gitlab-qa (14.9.0)
4
+ gitlab-qa (14.11.0)
5
5
  activesupport (>= 6.1, < 7.2)
6
6
  gitlab (~> 4.19)
7
7
  http (~> 5.0)
@@ -175,19 +175,19 @@ GEM
175
175
  reverse_markdown (2.1.1)
176
176
  nokogiri
177
177
  rexml (3.2.5)
178
- rspec (3.12.0)
179
- rspec-core (~> 3.12.0)
180
- rspec-expectations (~> 3.12.0)
181
- rspec-mocks (~> 3.12.0)
182
- rspec-core (3.12.0)
183
- rspec-support (~> 3.12.0)
184
- rspec-expectations (3.12.0)
178
+ rspec (3.13.0)
179
+ rspec-core (~> 3.13.0)
180
+ rspec-expectations (~> 3.13.0)
181
+ rspec-mocks (~> 3.13.0)
182
+ rspec-core (3.13.0)
183
+ rspec-support (~> 3.13.0)
184
+ rspec-expectations (3.13.0)
185
185
  diff-lcs (>= 1.2.0, < 2.0)
186
- rspec-support (~> 3.12.0)
187
- rspec-mocks (3.12.0)
186
+ rspec-support (~> 3.13.0)
187
+ rspec-mocks (3.13.1)
188
188
  diff-lcs (>= 1.2.0, < 2.0)
189
- rspec-support (~> 3.12.0)
190
- rspec-support (3.12.0)
189
+ rspec-support (~> 3.13.0)
190
+ rspec-support (3.13.1)
191
191
  rubocop (1.43.0)
192
192
  json (~> 2.3)
193
193
  parallel (~> 1.10)
@@ -280,7 +280,7 @@ DEPENDENCIES
280
280
  pry (~> 0.11)
281
281
  pry-byebug (~> 3.10.1)
282
282
  rake (~> 13.0)
283
- rspec (~> 3.7)
283
+ rspec (~> 3.13)
284
284
  simplecov (~> 0.22)
285
285
  simplecov-cobertura (~> 2.1)
286
286
  solargraph (~> 0.41)
@@ -63,6 +63,7 @@ All environment variables used by GitLab QA should be defined in [`lib/gitlab/qa
63
63
  | `QA_EE_ACTIVATION_CODE` |- | Cloud activation code to enable Enterprise Edition features. | No|
64
64
  | `QA_ARTIFACTS_DIR` |`/tmp/gitlab-qa`| Path to a directory where artifacts (logs and screenshots) for failing tests will be saved. | No|
65
65
  | `DOCKER_HOST` |`http://localhost`| Docker host to run tests against. | No|
66
+ | `QA_DOCKER_NETWORK` | `test` | Name of the Docker network that is created to allow connectivity between GitLab and other containers. | No |
66
67
  | `WEBDRIVER_HEADLESS` |- | When running locally, set to `false` to allow Chrome tests to be visible - watch your tests being run. | No|
67
68
  | `CHROME_DISABLE_DEV_SHM` | `false` | Set to `true` to disable `/dev/shm` usage in Chrome on Linux. | No|
68
69
  | `QA_ADDITIONAL_REPOSITORY_STORAGE` |- | The name of additional, non-default storage to be used with tests tagged `repository_storage`, run via the `Test::Instance::RepositoryStorage` scenario. Note: Admin access is required to change repository storage. | No|
@@ -333,7 +334,7 @@ Scenario verifies upgrade from previous (major|minor) version to current release
333
334
  - Deploys previous (major|minor) version and runs Smoke test suite
334
335
  to populate data in database before upgrade
335
336
  - Generates upgrade path following current GitLab recommendations
336
- from ['gitlab-com/support/toolbox/upgrade-path'](https://gitlab.com/gitlab-com/support/toolbox/upgrade-path/-/raw/main/upgrade-path.yml) project
337
+ from ['gitlab.com/gitlab-org/gitlab'](https://gitlab.com/gitlab-org/gitlab/-/raw/master/config/upgrade_path.yml) project
337
338
  - Gradually upgrades GitLab instances to `<current_version>`
338
339
  associated with provided `<full image address>` and runs tests against it
339
340
 
@@ -883,9 +884,9 @@ $ export GITLAB_PASSWORD="$GITLAB_QA_PASSWORD"
883
884
  $ gitlab-qa Test::Instance::StagingRef
884
885
  ```
885
886
 
886
- ### `Test::Instance::StagingGeo`
887
+ ### `Test::Instance::StagingRefGeo`
887
888
 
888
- This scenario tests that the Geo staging deployment (with [`staging.gitlab.com`](https://staging.gitlab.com) as the primary site and [`geo.staging.gitlab.com`](https://geo.staging.gitlab.com) as the secondary site) works as expected by running tests tagged `:geo` against it. This is done by spinning up a GitLab QA (`gitlab/gitlab-qa`) container and running the `QA::EE::Scenario::Test::Geo` scenario. Note that the Geo setup steps in the `QA::EE::Scenario::Test::Geo` scenario are skipped when testing a live Geo deployment.
889
+ This scenario tests that the Geo staging deployment (with [`staging-ref.gitlab.com`](https://staging-ref.gitlab.com) as the primary site and [`geo.staging-ref.gitlab.com`](https://geo.staging-ref.gitlab.com) as the secondary site) works as expected by running tests tagged `:geo` against it. This is done by spinning up a GitLab QA (`gitlab/gitlab-qa`) container and running the `QA::EE::Scenario::Test::Geo` scenario. Note that the Geo setup steps in the `QA::EE::Scenario::Test::Geo` scenario are skipped when testing a live Geo deployment.
889
890
 
890
891
  **Required user properties:**
891
892
 
@@ -907,23 +908,6 @@ This scenario tests that the Geo staging deployment (with [`staging.gitlab.com`]
907
908
  If the variable isn't present, the QA image from Docker Hub will be used.
908
909
  This can be found in the shared 1Password vault.
909
910
 
910
- Example:
911
-
912
- ```shell
913
- $ export GITLAB_QA_ACCESS_TOKEN=your_api_access_token
914
- $ export GITLAB_QA_DEV_ACCESS_TOKEN=your_dev_registry_access_token
915
- $ export GITLAB_USERNAME="gitlab-qa"
916
- $ export GITLAB_PASSWORD="$GITLAB_QA_PASSWORD"
917
-
918
- $ gitlab-qa Test::Instance::StagingGeo
919
- ```
920
-
921
- ### `Test::Instance::StagingRefGeo`
922
-
923
- This scenario tests that the Geo staging deployment (with [`staging-ref.gitlab.com`](https://staging-ref.gitlab.com) as the primary site and [`geo.staging-ref.gitlab.com`](https://geo.staging-ref.gitlab.com) as the secondary site) works as expected by running tests tagged `:geo` against it. This is done by spinning up a GitLab QA (`gitlab/gitlab-qa`) container and running the `QA::EE::Scenario::Test::Geo` scenario. Note that the Geo setup steps in the `QA::EE::Scenario::Test::Geo` scenario are skipped when testing a live Geo deployment.
924
-
925
- Scenario requirements are the same as [`Test::Instance::StagingGeo`](#testinstancestaginggeo) described above.
926
-
927
911
  ```shell
928
912
  $ export GITLAB_QA_ACCESS_TOKEN=your_api_access_token
929
913
  $ export GITLAB_QA_DEV_ACCESS_TOKEN=your_dev_registry_access_token
@@ -1034,7 +1018,7 @@ These tests verify features related to multiple repository storages.
1034
1018
  Example:
1035
1019
 
1036
1020
  ```shell
1037
- $ export QA_ADDITIONAL_REPOSITORY_STORAGE=secondary
1021
+ $ export QA_ADDITIONAL_REPOSITORY_STORAGE=secondary
1038
1022
  $ export QA_GITALY_NON_CLUSTER_STORAGE=gitaly
1039
1023
  $ export QA_PRAEFECT_REPOSITORY_STORAGE=praefect
1040
1024
 
data/gitlab-qa.gemspec CHANGED
@@ -29,7 +29,7 @@ Gem::Specification.new do |spec|
29
29
  spec.add_development_dependency 'pry', '~> 0.11'
30
30
  spec.add_development_dependency 'pry-byebug', '~> 3.10.1'
31
31
  spec.add_development_dependency 'rake', '~> 13.0'
32
- spec.add_development_dependency 'rspec', '~> 3.7'
32
+ spec.add_development_dependency 'rspec', '~> 3.13'
33
33
  spec.add_development_dependency 'simplecov', '~> 0.22'
34
34
  spec.add_development_dependency 'simplecov-cobertura', '~> 2.1'
35
35
  spec.add_development_dependency 'solargraph', '~> 0.41'
@@ -189,7 +189,7 @@ module Gitlab
189
189
  raise 'Invalid instance name!' unless name
190
190
  end
191
191
 
192
- def instance_no_teardown
192
+ def instance_no_teardown # rubocop:disable Metrics/AbcSize
193
193
  begin
194
194
  retries ||= 0
195
195
  prepare
@@ -201,12 +201,17 @@ module Gitlab
201
201
  reconfigure_log_file = get_reconfigure_log_file_from_artefact
202
202
  # for scenarios where a service fails during startup, attempt to retry to avoid flaky failures
203
203
  if (retries += 1) < 3
204
- Runtime::Logger.info(
205
- "Follow the document " \
206
- "https://gitlab.com/gitlab-org/quality/runbooks/-/blob/main/debug_orchestrated_test_locally/ " \
207
- "for debugging the test failure locally.")
208
- Runtime::Logger.error("Tailing the reconfigure log file: #{reconfigure_log_file}. Please check #{reconfigure_log_file} " \
209
- "file in the artifacts for more details.")
204
+ unless reconfigure_log_file.nil?
205
+ Runtime::Logger.info(
206
+ "Follow the document " \
207
+ "https://gitlab.com/gitlab-org/quality/runbooks/-/blob/main/debug_orchestrated_test_locally/ " \
208
+ "for debugging the test failure locally.")
209
+
210
+ # Tailing the reconfigure logs after retries are over and before raising exception
211
+ Runtime::Logger.info("Tail of the reconfigure log file, see artifacts for full log: #{reconfigure_log_file}")
212
+ Support::ShellCommand.new("tail -n 100 #{reconfigure_log_file}", stream_output: true).execute!
213
+ end
214
+
210
215
  Runtime::Logger.warn(
211
216
  "Retry instance_no_teardown due to Support::ShellCommand::StatusError -- attempt #{retries}"
212
217
  )
@@ -214,9 +219,14 @@ module Gitlab
214
219
  retry
215
220
  end
216
221
 
217
- # Tailing the reconfigure logs after retries are over and before raising exception
218
- Runtime::Logger.info("Tail of the reconfigure log file, see artifacts for full log: #{reconfigure_log_file}")
219
- Support::ShellCommand.new("tail -n 100 #{reconfigure_log_file}", stream_output: true).execute!
222
+ # Printing logs to stdout for last retry failure
223
+
224
+ if !reconfigure_log_file.nil? && retries == 3
225
+ # Tailing the reconfigure logs after retries are over and before raising exception
226
+ Runtime::Logger.info("Tail of the reconfigure log file, see artifacts for full log: #{reconfigure_log_file}")
227
+ Support::ShellCommand.new("tail -n 100 #{reconfigure_log_file}", stream_output: true).execute!
228
+ end
229
+
220
230
  raise e
221
231
  end
222
232
 
@@ -11,7 +11,7 @@ module Gitlab
11
11
 
12
12
  def initialize
13
13
  super
14
- @network = "test"
14
+ @network = Runtime::Env.docker_network
15
15
  end
16
16
 
17
17
  def name
@@ -67,7 +67,8 @@ module Gitlab
67
67
  gitaly['configuration'] = {
68
68
  'listen_addr': '0.0.0.0:#{gitaly_port}',
69
69
  'prometheus_listen_addr': '0.0.0.0:9236',
70
- 'auth_token': 'PRAEFECT_INTERNAL_TOKEN'
70
+ 'auth_token': 'PRAEFECT_INTERNAL_TOKEN',
71
+ 'transactions': {'enabled': #{Runtime::Env.qa_gitaly_transactions_enabled?}}
71
72
  }
72
73
  gitlab_shell['secret_token'] = 'GITLAB_SHELL_SECRET_TOKEN';
73
74
  gitlab_rails['internal_api_url'] = 'http://#{cluster_config.gitlab_name}.#{cluster_config.network}';
@@ -16,7 +16,7 @@ module Gitlab
16
16
 
17
17
  def initialize(params = {}) # rubocop:disable Metrics/AbcSize, Metrics/CyclomaticComplexity
18
18
  @gitlab_name = params[:gitlab_name] || 'gitlab-gitaly-cluster'
19
- @network = params[:network] || 'test'
19
+ @network = params[:network] || Runtime::Env.docker_network
20
20
  @airgapped_network = params[:airgapped_network] || false
21
21
 
22
22
  @praefect_node_name = params[:praefect_node_name] || 'praefect'
@@ -93,7 +93,6 @@ module Gitlab
93
93
  scenario = Scenario.const_get(args.shift)
94
94
 
95
95
  load_omnibus_configurations
96
- load_telegraf(scenario)
97
96
 
98
97
  begin
99
98
  @active_configurators.compact.each do |configurator|
@@ -129,18 +128,6 @@ module Gitlab
129
128
  end.compact
130
129
  end
131
130
 
132
- # Start telegraf agent for metrics collection
133
- #
134
- # Do not load when running against external instance
135
- #
136
- # @param [Class] scenario
137
- # @return [void]
138
- def self.load_telegraf(scenario)
139
- return if scenario <= Scenario::Test::Instance::DeploymentBase || scenario == Scenario::Test::Instance::Any
140
-
141
- @active_configurators << Component::Telegraf.new
142
- end
143
-
144
131
  def self.load_omnibus_configurations
145
132
  # OmnibusConfiguration::Test => --test
146
133
  # OmnibusConfiguration::HelloThere => --hello_there
@@ -17,156 +17,156 @@ module Gitlab
17
17
  # Any new key-value pairs should also be added to the hash at /rubocop/cop/gitlab/dangerous_interpolation.rb
18
18
  # to prevent Rubocop errors.
19
19
  ENV_VARIABLES = {
20
- 'QA_IMAGE' => :qa_image,
21
- 'QA_REMOTE_GRID' => :remote_grid,
22
- 'QA_REMOTE_GRID_USERNAME' => :remote_grid_username,
23
- 'QA_REMOTE_GRID_ACCESS_KEY' => :remote_grid_access_key,
24
- 'QA_REMOTE_GRID_PROTOCOL' => :remote_grid_protocol,
25
- 'QA_REMOTE_MOBILE_DEVICE_NAME' => :remote_mobile_device_name,
26
- 'QA_REMOTE_TUNNEL_ID' => :remote_tunnel_id,
27
- 'QA_BROWSER' => :browser,
28
- 'QA_SELENOID_BROWSER_VERSION' => :selenoid_browser_version,
29
- 'QA_RECORD_VIDEO' => :record_video,
30
- 'QA_LAYOUT' => :layout,
31
- 'QA_VIDEO_RECORDER_IMAGE' => :video_recorder_image,
32
- 'QA_VIDEO_RECORDER_VERSION' => :video_recorder_version,
33
- 'QA_SELENOID_BROWSER_IMAGE' => :selenoid_browser_image,
34
- 'QA_ADDITIONAL_REPOSITORY_STORAGE' => :qa_additional_repository_storage,
35
- 'QA_PRAEFECT_REPOSITORY_STORAGE' => :qa_praefect_repository_storage,
36
- 'QA_GITALY_NON_CLUSTER_STORAGE' => :qa_gitaly_non_cluster_storage,
37
- 'QA_COOKIES' => :qa_cookie,
38
- 'QA_DEBUG' => :qa_debug,
39
- 'QA_CAN_TEST_ADMIN_FEATURES' => :qa_can_test_admin_features,
40
- 'QA_CAN_TEST_GIT_PROTOCOL_V2' => :qa_can_test_git_protocol_v2,
41
- 'QA_CAN_TEST_PRAEFECT' => :qa_can_test_praefect,
42
- 'QA_SIMULATE_SLOW_CONNECTION' => :qa_simulate_slow_connection,
43
- 'QA_SLOW_CONNECTION_LATENCY_MS' => :qa_slow_connection_latency_ms,
44
- 'QA_SLOW_CONNECTION_THROUGHPUT_KBPS' => :qa_slow_connection_throughput_kbps,
45
- 'QA_GENERATE_ALLURE_REPORT' => :generate_allure_report,
46
- 'QA_EXPORT_TEST_METRICS' => :qa_export_test_metrics,
47
- 'QA_INFLUXDB_URL' => :qa_influxdb_url,
48
- 'QA_INFLUXDB_TOKEN' => :qa_influxdb_token,
49
- 'QA_SKIP_PULL' => :qa_skip_pull,
50
- 'QA_VALIDATE_RESOURCE_REUSE' => :qa_validate_resource_reuse,
51
- 'WEBDRIVER_HEADLESS' => :webdriver_headless,
52
- 'GITLAB_ADMIN_USERNAME' => :admin_username,
53
- 'GITLAB_ADMIN_PASSWORD' => :admin_password,
54
- 'GITLAB_USERNAME' => :user_username,
55
- 'GITLAB_PASSWORD' => :user_password,
56
- 'GITLAB_LDAP_USERNAME' => :ldap_username,
57
- 'GITLAB_LDAP_PASSWORD' => :ldap_password,
58
- 'GITLAB_FORKER_USERNAME' => :forker_username,
59
- 'GITLAB_FORKER_PASSWORD' => :forker_password,
60
- 'GITLAB_USER_TYPE' => :user_type,
61
- 'GITLAB_SANDBOX_NAME' => :gitlab_sandbox_name,
62
- 'GITLAB_QA_ACCESS_TOKEN' => :qa_access_token,
63
- 'GITLAB_QA_ADMIN_ACCESS_TOKEN' => :qa_admin_access_token,
64
- 'GITLAB_QA_DEV_ACCESS_TOKEN' => :qa_dev_access_token,
65
- 'GITLAB_QA_CONTAINER_REGISTRY_ACCESS_TOKEN' => :qa_container_registry_access_token,
66
- 'GITHUB_ACCESS_TOKEN' => :github_access_token,
67
- 'GITLAB_URL' => :gitlab_url,
68
- 'SIMPLE_SAML_HOSTNAME' => :simple_saml_hostname,
69
- 'SIMPLE_SAML_FINGERPRINT' => :simple_saml_fingerprint,
70
20
  'ACCEPT_INSECURE_CERTS' => :accept_insecure_certs,
71
- 'EE_LICENSE' => :ee_license,
72
- 'GCLOUD_ACCOUNT_EMAIL' => :gcloud_account_email,
73
- 'GCLOUD_ACCOUNT_KEY' => :gcloud_account_key,
74
- 'CLOUDSDK_CORE_PROJECT' => :cloudsdk_core_project,
75
- 'GCLOUD_REGION' => :gcloud_region,
76
- 'SIGNUP_DISABLED' => :signup_disabled,
77
- 'GITLAB_QA_USERNAME_1' => :gitlab_qa_username_1,
78
- 'GITLAB_QA_PASSWORD_1' => :gitlab_qa_password_1,
79
- 'GITLAB_QA_USERNAME_2' => :gitlab_qa_username_2,
80
- 'GITLAB_QA_PASSWORD_2' => :gitlab_qa_password_2,
81
- 'QA_GITHUB_USERNAME' => :qa_github_username,
82
- 'QA_GITHUB_PASSWORD' => :qa_github_password,
83
- 'QA_GITLAB_HOSTNAME' => :qa_gitlab_hostname,
84
- 'QA_GITLAB_USE_TLS' => :qa_gitlab_use_tls,
85
- 'KNAPSACK_GENERATE_REPORT' => :knapsack_generate_report,
86
- 'KNAPSACK_REPORT_PATH' => :knapsack_report_path,
87
- 'KNAPSACK_TEST_FILE_PATTERN' => :knapsack_test_file_pattern,
88
- 'KNAPSACK_TEST_DIR' => :knapsack_test_dir,
89
- 'NO_KNAPSACK' => :no_knapsack,
90
- 'QA_KNAPSACK_REPORT_GCS_CREDENTIALS' => :qa_knapsack_report_gcs_credentials,
91
- 'QA_KNAPSACK_REPORT_PATH' => :qa_knapsack_report_path,
92
- 'QA_RSPEC_REPORT_PATH' => :qa_rspec_report_path,
93
- 'RSPEC_FAST_QUARANTINE_PATH' => :rspec_fast_quarantine_path,
94
- 'RSPEC_SKIPPED_TESTS_REPORT_PATH' => :skipped_tests_report_path,
21
+ 'AWS_S3_ACCESS_KEY' => :aws_s3_access_key,
22
+ 'AWS_S3_BUCKET_NAME' => :aws_s3_bucket_name,
23
+ 'AWS_S3_KEY_ID' => :aws_s3_key_id,
24
+ 'AWS_S3_REGION' => :aws_s3_region,
25
+ 'CACHE_NAMESPACE_NAME' => :cache_namespace_name,
26
+ 'CHROME_DISABLE_DEV_SHM' => :chrome_disable_dev_shm,
95
27
  'CI' => :ci,
28
+ 'CI_JOB_ID' => :ci_job_id,
96
29
  'CI_JOB_NAME' => :ci_job_name,
97
30
  'CI_JOB_NAME_SLUG' => :ci_job_name_slug,
98
- 'CI_JOB_ID' => :ci_job_id,
99
- 'CI_JOB_URL' => :ci_job_url,
100
31
  'CI_JOB_TOKEN' => :ci_job_token,
101
- 'CI_RUNNER_ID' => :ci_runner_id,
102
- 'CI_SERVER_HOST' => :ci_server_host,
103
- 'CI_SERVER_PERSONAL_ACCESS_TOKEN' => :ci_server_personal_access_token,
32
+ 'CI_JOB_URL' => :ci_job_url,
33
+ 'CI_MERGE_REQUEST_IID' => :ci_merge_request_iid,
104
34
  'CI_NODE_INDEX' => :ci_node_index,
105
35
  'CI_NODE_TOTAL' => :ci_node_total,
36
+ 'CI_PIPELINE_CREATED_AT' => :ci_pipeline_created_at,
37
+ 'CI_PIPELINE_ID' => :ci_pipeline_id,
38
+ 'CI_PIPELINE_SOURCE' => :ci_pipeline_source,
39
+ 'CI_PIPELINE_URL' => :ci_pipeline_url,
106
40
  'CI_PROJECT_NAME' => :ci_project_name,
107
41
  'CI_PROJECT_PATH' => :ci_project_path,
108
42
  'CI_PROJECT_PATH_SLUG' => :ci_project_path_slug,
109
- 'CI_PIPELINE_SOURCE' => :ci_pipeline_source,
110
- 'CI_PIPELINE_ID' => :ci_pipeline_id,
111
- 'CI_PIPELINE_URL' => :ci_pipeline_url,
112
- 'CI_PIPELINE_CREATED_AT' => :ci_pipeline_created_at,
113
- 'CI_MERGE_REQUEST_IID' => :ci_merge_request_iid,
114
- 'GITLAB_CI' => :gitlab_ci,
43
+ 'CI_RUNNER_ID' => :ci_runner_id,
44
+ 'CI_SERVER_HOST' => :ci_server_host,
45
+ 'CI_SERVER_PERSONAL_ACCESS_TOKEN' => :ci_server_personal_access_token,
46
+ 'COLORIZED_LOGS' => :colorized_logs,
47
+ 'CLOUDSDK_CORE_PROJECT' => :cloudsdk_core_project,
48
+ 'EE_LICENSE' => :ee_license,
115
49
  'ELASTIC_URL' => :elastic_url,
116
- 'GITLAB_QA_LOOP_RUNNER_MINUTES' => :gitlab_qa_loop_runner_minutes,
117
- 'MAILHOG_HOSTNAME' => :mailhog_hostname,
118
- 'GITLAB_QA_FORMLESS_LOGIN_TOKEN' => :gitlab_qa_formless_login_token,
119
- 'GEO_MAX_FILE_REPLICATION_TIME' => :geo_max_file_replication_time,
120
- 'GEO_MAX_DB_REPLICATION_TIME' => :geo_max_db_replication_time,
121
- 'JIRA_HOSTNAME' => :jira_hostname,
122
- 'JIRA_ADMIN_USERNAME' => :jira_admin_username,
123
- 'JIRA_ADMIN_PASSWORD' => :jira_admin_password,
124
- 'CACHE_NAMESPACE_NAME' => :cache_namespace_name,
125
- 'GITLAB_QA_USER_AGENT' => :gitlab_qa_user_agent,
50
+ 'FIPS' => :fips,
51
+ 'GCS_BUCKET_NAME' => :gcs_bucket_name,
52
+ 'GCS_CDN_BUCKET_NAME' => :gcs_cdn_bucket_name,
53
+ 'GCLOUD_ACCOUNT_EMAIL' => :gcloud_account_email,
54
+ 'GCLOUD_ACCOUNT_KEY' => :gcloud_account_key,
55
+ 'GCLOUD_REGION' => :gcloud_region,
126
56
  'GEO_FAILOVER' => :geo_failover,
57
+ 'GEO_MAX_DB_REPLICATION_TIME' => :geo_max_db_replication_time,
58
+ 'GEO_MAX_FILE_REPLICATION_TIME' => :geo_max_file_replication_time,
59
+ 'GITLAB_ADMIN_PASSWORD' => :admin_password,
60
+ 'GITLAB_ADMIN_USERNAME' => :admin_username,
61
+ 'GITLAB_FORKER_PASSWORD' => :forker_password,
62
+ 'GITLAB_FORKER_USERNAME' => :forker_username,
127
63
  'GITLAB_INITIAL_ROOT_PASSWORD' => :initial_root_password,
64
+ 'GITLAB_LDAP_PASSWORD' => :ldap_password,
65
+ 'GITLAB_LDAP_USERNAME' => :ldap_username,
66
+ 'GITLAB_PASSWORD' => :user_password,
67
+ 'GITLAB_QA_ACCESS_TOKEN' => :qa_access_token,
68
+ 'GITLAB_QA_ADMIN_ACCESS_TOKEN' => :qa_admin_access_token,
69
+ 'GITLAB_QA_CONTAINER_REGISTRY_ACCESS_TOKEN' => :qa_container_registry_access_token,
70
+ 'GITLAB_QA_DEV_ACCESS_TOKEN' => :qa_dev_access_token,
71
+ 'GITLAB_QA_FORMLESS_LOGIN_TOKEN' => :gitlab_qa_formless_login_token,
72
+ 'GITLAB_QA_LOOP_RUNNER_MINUTES' => :gitlab_qa_loop_runner_minutes,
73
+ 'GITLAB_QA_PASSWORD_1' => :gitlab_qa_password_1,
74
+ 'GITLAB_QA_PASSWORD_2' => :gitlab_qa_password_2,
75
+ 'GITLAB_QA_USER_AGENT' => :gitlab_qa_user_agent,
76
+ 'GITLAB_QA_USERNAME_1' => :gitlab_qa_username_1,
77
+ 'GITLAB_QA_USERNAME_2' => :gitlab_qa_username_2,
78
+ 'GITLAB_SANDBOX_NAME' => :gitlab_sandbox_name,
128
79
  'GITLAB_TLS_CERTIFICATE' => :gitlab_tls_certificate,
129
- 'AWS_S3_REGION' => :aws_s3_region,
130
- 'AWS_S3_KEY_ID' => :aws_s3_key_id,
131
- 'AWS_S3_ACCESS_KEY' => :aws_s3_access_key,
132
- 'AWS_S3_BUCKET_NAME' => :aws_s3_bucket_name,
133
- 'TOP_UPSTREAM_MERGE_REQUEST_IID' => :top_upstream_merge_request_iid,
134
- 'GOOGLE_PROJECT' => :google_project,
135
- 'GOOGLE_CLIENT_EMAIL' => :google_client_email,
136
- 'GOOGLE_JSON_KEY' => :google_json_key,
80
+ 'GITLAB_URL' => :gitlab_url,
81
+ 'GITLAB_USER_TYPE' => :user_type,
82
+ 'GITLAB_USERNAME' => :user_username,
83
+ 'GITLAB_CI' => :gitlab_ci,
84
+ 'GITHUB_ACCESS_TOKEN' => :github_access_token,
137
85
  'GOOGLE_CDN_JSON_KEY' => :google_cdn_json_key,
138
86
  'GOOGLE_CDN_LB' => :google_cdn_load_balancer,
139
87
  'GOOGLE_CDN_SIGNURL_KEY' => :google_cdn_signurl_key,
140
88
  'GOOGLE_CDN_SIGNURL_KEY_NAME' => :google_cdn_signurl_key_name,
141
- 'GCS_CDN_BUCKET_NAME' => :gcs_cdn_bucket_name,
142
- 'GCS_BUCKET_NAME' => :gcs_bucket_name,
143
- 'SMOKE_ONLY' => :smoke_only,
144
- 'NO_ADMIN' => :no_admin,
145
- 'CHROME_DISABLE_DEV_SHM' => :chrome_disable_dev_shm,
146
- 'COLORIZED_LOGS' => :colorized_logs,
147
- 'FIPS' => :fips,
89
+ 'GOOGLE_CLIENT_EMAIL' => :google_client_email,
90
+ 'GOOGLE_JSON_KEY' => :google_json_key,
91
+ 'GOOGLE_PROJECT' => :google_project,
148
92
  'JH_ENV' => :jh_env,
93
+ 'JIRA_ADMIN_PASSWORD' => :jira_admin_password,
94
+ 'JIRA_ADMIN_USERNAME' => :jira_admin_username,
95
+ 'JIRA_HOSTNAME' => :jira_hostname,
96
+ 'KNAPSACK_GENERATE_REPORT' => :knapsack_generate_report,
97
+ 'KNAPSACK_REPORT_PATH' => :knapsack_report_path,
98
+ 'KNAPSACK_TEST_DIR' => :knapsack_test_dir,
99
+ 'KNAPSACK_TEST_FILE_PATTERN' => :knapsack_test_file_pattern,
100
+ 'MAILHOG_HOSTNAME' => :mailhog_hostname,
101
+ 'NO_KNAPSACK' => :no_knapsack,
102
+ 'QA_ADDITIONAL_REPOSITORY_STORAGE' => :qa_additional_repository_storage,
103
+ 'QA_BROWSER' => :browser,
104
+ 'QA_CAN_TEST_ADMIN_FEATURES' => :qa_can_test_admin_features,
105
+ 'QA_CAN_TEST_GIT_PROTOCOL_V2' => :qa_can_test_git_protocol_v2,
106
+ 'QA_CAN_TEST_PRAEFECT' => :qa_can_test_praefect,
107
+ 'QA_COOKIES' => :qa_cookie,
108
+ 'QA_DEBUG' => :qa_debug,
109
+ 'QA_DOCKER_NETWORK' => :docker_network,
110
+ 'QA_EXPORT_TEST_METRICS' => :qa_export_test_metrics,
111
+ 'QA_GITALY_NON_CLUSTER_STORAGE' => :qa_gitaly_non_cluster_storage,
149
112
  'QA_GITHUB_OAUTH_APP_ID' => :github_oauth_app_id,
150
113
  'QA_GITHUB_OAUTH_APP_SECRET' => :github_oauth_app_secret,
114
+ 'QA_GITHUB_PASSWORD' => :qa_github_password,
115
+ 'QA_GITHUB_USERNAME' => :qa_github_username,
116
+ 'QA_GITLAB_HOSTNAME' => :qa_gitlab_hostname,
117
+ 'QA_GITLAB_USE_TLS' => :qa_gitlab_use_tls,
118
+ 'QA_IMAGE' => :qa_image,
119
+ 'QA_INFLUXDB_TOKEN' => :qa_influxdb_token,
120
+ 'QA_INFLUXDB_URL' => :qa_influxdb_url,
121
+ 'QA_KNAPSACK_REPORT_GCS_CREDENTIALS' => :qa_knapsack_report_gcs_credentials,
122
+ 'QA_KNAPSACK_REPORT_PATH' => :qa_knapsack_report_path,
123
+ 'QA_LAYOUT' => :layout,
124
+ 'QA_PRAEFECT_REPOSITORY_STORAGE' => :qa_praefect_repository_storage,
125
+ 'QA_RECORD_VIDEO' => :record_video,
126
+ 'QA_REMOTE_GRID' => :remote_grid,
127
+ 'QA_REMOTE_GRID_ACCESS_KEY' => :remote_grid_access_key,
128
+ 'QA_REMOTE_GRID_PROTOCOL' => :remote_grid_protocol,
129
+ 'QA_REMOTE_GRID_USERNAME' => :remote_grid_username,
130
+ 'QA_REMOTE_MOBILE_DEVICE_NAME' => :remote_mobile_device_name,
131
+ 'QA_REMOTE_TUNNEL_ID' => :remote_tunnel_id,
132
+ 'QA_RSPEC_REPORT_PATH' => :qa_rspec_report_path,
133
+ 'QA_SELENOID_BROWSER_IMAGE' => :selenoid_browser_image,
134
+ 'QA_SELENOID_BROWSER_VERSION' => :selenoid_browser_version,
135
+ 'QA_SIMULATE_SLOW_CONNECTION' => :qa_simulate_slow_connection,
136
+ 'QA_SKIP_PULL' => :qa_skip_pull,
137
+ 'QA_SLOW_CONNECTION_LATENCY_MS' => :qa_slow_connection_latency_ms,
138
+ 'QA_SLOW_CONNECTION_THROUGHPUT_KBPS' => :qa_slow_connection_throughput_kbps,
139
+ 'QA_VALIDATE_RESOURCE_REUSE' => :qa_validate_resource_reuse,
140
+ 'QA_VIDEO_RECORDER_IMAGE' => :video_recorder_image,
141
+ 'QA_VIDEO_RECORDER_VERSION' => :video_recorder_version,
151
142
  'QA_1P_EMAIL' => :qa_1p_email,
143
+ 'QA_1P_GITHUB_UUID' => :qa_1p_github_uuid,
152
144
  'QA_1P_PASSWORD' => :qa_1p_password,
153
145
  'QA_1P_SECRET' => :qa_1p_secret,
154
- 'QA_1P_GITHUB_UUID' => :qa_1p_github_uuid,
155
146
  'RELEASE' => :release,
147
+ 'RELEASE_REGISTRY_PASSWORD' => :release_registry_password,
156
148
  'RELEASE_REGISTRY_URL' => :release_registry_url,
157
149
  'RELEASE_REGISTRY_USERNAME' => :release_registry_username,
158
- 'RELEASE_REGISTRY_PASSWORD' => :release_registry_password,
150
+ 'RSPEC_FAST_QUARANTINE_PATH' => :rspec_fast_quarantine_path,
151
+ 'RSPEC_SKIPPED_TESTS_REPORT_PATH' => :skipped_tests_report_path,
152
+ 'SCHEDULE_TYPE' => :schedule_type,
159
153
  'SELENOID_DIRECTORY' => :selenoid_directory,
154
+ 'SIGNUP_DISABLED' => :signup_disabled,
155
+ 'SIMPLE_SAML_FINGERPRINT' => :simple_saml_fingerprint,
156
+ 'SIMPLE_SAML_HOSTNAME' => :simple_saml_hostname,
157
+ 'SMOKE_ONLY' => :smoke_only,
158
+ 'TOP_UPSTREAM_MERGE_REQUEST_IID' => :top_upstream_merge_request_iid,
160
159
  'USE_SELENOID' => :use_selenoid,
161
- 'SCHEDULE_TYPE' => :schedule_type,
160
+ 'WEBDRIVER_HEADLESS' => :webdriver_headless,
161
+ 'WORKSPACES_DOMAIN_CERT' => { name: :workspaces_domain_cert, type: :file },
162
+ 'WORKSPACES_DOMAIN_KEY' => { name: :workspaces_domain_key, type: :file },
162
163
  'WORKSPACES_OAUTH_APP_ID' => :workspaces_oauth_app_id,
163
164
  'WORKSPACES_OAUTH_APP_SECRET' => :workspaces_oauth_app_secret,
164
165
  'WORKSPACES_OAUTH_SIGNING_KEY' => :workspaces_oauth_signing_key,
165
166
  'WORKSPACES_PROXY_DOMAIN' => :workspaces_proxy_domain,
166
- 'WORKSPACES_DOMAIN_CERT' => { name: :workspaces_domain_cert, type: :file },
167
- 'WORKSPACES_DOMAIN_KEY' => { name: :workspaces_domain_key, type: :file },
168
167
  'WORKSPACES_WILDCARD_CERT' => { name: :workspaces_wildcard_cert, type: :file },
169
- 'WORKSPACES_WILDCARD_KEY' => { name: :workspaces_wildcard_key, type: :file }
168
+ 'WORKSPACES_WILDCARD_KEY' => { name: :workspaces_wildcard_key, type: :file },
169
+ 'EPIC_SYNC_TEST' => :epic_sync_test
170
170
  }.freeze
171
171
 
172
172
  def variables
@@ -370,7 +370,8 @@ module Gitlab
370
370
  end
371
371
 
372
372
  def video_recorder_image
373
- env_var_value_if_defined('QA_VIDEO_RECORDER_IMAGE') || 'registry.gitlab.com/gitlab-org/gitlab-qa/selenoid-manual-video-recorder'
373
+ env_var_value_if_defined('QA_VIDEO_RECORDER_IMAGE') ||
374
+ 'registry.gitlab.com/gitlab-org/gitlab-qa/selenoid-manual-video-recorder'
374
375
  end
375
376
 
376
377
  def video_recorder_version
@@ -391,9 +392,7 @@ module Gitlab
391
392
  live_envs = %w[staging staging-canary staging-ref canary preprod production]
392
393
  return unless live_envs.include?(ci_project_name)
393
394
 
394
- test_subset = if env_var_value_if_defined('NO_ADMIN') == 'true'
395
- 'sanity-no-admin'
396
- elsif env_var_value_if_defined('SMOKE_ONLY') == 'true'
395
+ test_subset = if env_var_value_if_defined('SMOKE_ONLY') == 'true'
397
396
  'sanity'
398
397
  else
399
398
  'full'
@@ -402,6 +401,13 @@ module Gitlab
402
401
  "#{ci_project_name}-#{test_subset}"
403
402
  end
404
403
 
404
+ # The default network for the Docker containers
405
+ #
406
+ # @example <component>.test
407
+ def docker_network
408
+ env_var_value_if_defined('QA_DOCKER_NETWORK') || 'test'
409
+ end
410
+
405
411
  def docker_add_hosts
406
412
  (env_var_value_if_defined('QA_DOCKER_ADD_HOSTS') || '').split(',')
407
413
  end
@@ -470,6 +476,10 @@ module Gitlab
470
476
  enabled?(env_var_value_if_defined('QA_RETRY_FAILED_SPECS'), default: false)
471
477
  end
472
478
 
479
+ def self.qa_gitaly_transactions_enabled?
480
+ enabled?(env_var_value_if_defined('QA_GITALY_TRANSACTIONS_ENABLED'), default: false)
481
+ end
482
+
473
483
  private
474
484
 
475
485
  def enabled?(value, default: true)
@@ -21,7 +21,7 @@ module Gitlab
21
21
  end
22
22
 
23
23
  def prepare
24
- minio.network = 'test'
24
+ minio.network = Runtime::Env.docker_network
25
25
 
26
26
  TYPES.each do |bucket_name|
27
27
  minio.add_bucket("#{bucket_name}-bucket")
@@ -13,7 +13,7 @@ module Gitlab
13
13
  # Uses https://docs.docker.com/engine/reference/commandline/network_create/#network-internal-mode
14
14
  @airgapped_network_name = 'airgapped'
15
15
  # Uses iptables to deny all network traffic, with a number of exceptions for required ports and IPs
16
- @iptables_restricted_network = 'test'
16
+ @iptables_restricted_network = Runtime::Env.docker_network
17
17
  @config = Component::GitalyCluster::GitalyClusterConfig.new(
18
18
  gitlab_name: "gitlab-airgapped-#{SecureRandom.hex(4)}",
19
19
  airgapped_network: true,
@@ -37,7 +37,7 @@ module Gitlab
37
37
  gitlab.skip_availability_check = true
38
38
  gitlab.omnibus_configuration << gitlab_omnibus_configuration
39
39
  rspec_args << "--" unless rspec_args.include?('--')
40
- rspec_args << %w[--tag ~orchestrated]
40
+ rspec_args << "--tag ~orchestrated"
41
41
  gitlab.instance do
42
42
  Component::Specs.perform do |specs|
43
43
  specs.suite = 'Test::Instance::Airgapped'