Sha256: 8ca4349d5fd970d41f0c1b86963c63b0c4adfc19c0f208a12ba27e3b5ed2a857

Contents?: true

Size: 1.41 KB

Versions: 70

Compression:

Stored size: 1.41 KB

Contents

# frozen_string_literal: true

module Gitlab
  module QA
    module Scenario
      module Test
        module Integration
          class Metrics < Scenario::Template
            PUMA_METRICS_SERVER_PORT = 8083
            SIDEKIQ_METRICS_SERVER_PORT = 8082

            def perform(release, *rspec_args)
              Component::Gitlab.perform do |gitlab|
                gitlab.release = release
                gitlab.network = 'test'
                gitlab.name = 'gitlab'
                gitlab.ports = [PUMA_METRICS_SERVER_PORT, SIDEKIQ_METRICS_SERVER_PORT]

                gitlab.omnibus_configuration << <<~RUBY
                  puma['exporter_enabled'] = true
                  puma['exporter_address'] = '0.0.0.0'
                  puma['exporter_port'] = #{PUMA_METRICS_SERVER_PORT}
                  sidekiq['metrics_enabled'] = true
                  sidekiq['listen_address'] = '0.0.0.0'
                  sidekiq['listen_port'] = #{SIDEKIQ_METRICS_SERVER_PORT}
                RUBY

                gitlab.instance do
                  Component::Specs.perform do |specs|
                    specs.suite = 'Test::Integration::Metrics'
                    specs.release = gitlab.release
                    specs.network = gitlab.network
                    specs.args = [gitlab.address, *rspec_args]
                  end
                end
              end
            end
          end
        end
      end
    end
  end
end

Version data entries

70 entries across 70 versions & 1 rubygems

Version Path
gitlab-qa-8.8.0 lib/gitlab/qa/scenario/test/integration/metrics.rb
gitlab-qa-8.7.0 lib/gitlab/qa/scenario/test/integration/metrics.rb
gitlab-qa-8.6.0 lib/gitlab/qa/scenario/test/integration/metrics.rb
gitlab-qa-8.5.0 lib/gitlab/qa/scenario/test/integration/metrics.rb
gitlab-qa-8.4.2 lib/gitlab/qa/scenario/test/integration/metrics.rb
gitlab-qa-8.4.1 lib/gitlab/qa/scenario/test/integration/metrics.rb
gitlab-qa-8.4.0 lib/gitlab/qa/scenario/test/integration/metrics.rb
gitlab-qa-8.3.2 lib/gitlab/qa/scenario/test/integration/metrics.rb
gitlab-qa-8.3.1 lib/gitlab/qa/scenario/test/integration/metrics.rb
gitlab-qa-8.3.0 lib/gitlab/qa/scenario/test/integration/metrics.rb