Commit e9725a0f authored by Anastasia McDonald's avatar Anastasia McDonald

Merge branch '352923-passing-max-20-variables' into 'master'

Saving max 20 variables to dotenv

See merge request gitlab-org/gitlab!83665
parents b814e3a5 ca0a19b3
......@@ -3,8 +3,8 @@
module QA
RSpec.describe 'Verify', :runner do
describe 'Pass dotenv variables to downstream via bridge' do
let(:executor) { "qa-runner-#{Faker::Alphanumeric.alphanumeric(8)}" }
let(:upstream_var) { Faker::Alphanumeric.alphanumeric(8) }
let(:executor) { "qa-runner-#{Faker::Alphanumeric.alphanumeric(number: 8)}" }
let(:upstream_var) { Faker::Alphanumeric.alphanumeric(number: 8) }
let(:group) { Resource::Group.fabricate_via_api! }
let(:upstream_project) do
......@@ -73,7 +73,7 @@ module QA
stage: build
tags: ["#{executor}"]
script:
- echo "DYNAMIC_ENVIRONMENT_VAR=#{upstream_var}" >> variables.env
- for i in `seq 1 20`; do echo "VAR_$i=#{upstream_var}" >> variables.env; done;
artifacts:
reports:
dotenv: variables.env
......@@ -81,7 +81,7 @@ module QA
trigger:
stage: deploy
variables:
PASSED_MY_VAR: $DYNAMIC_ENVIRONMENT_VAR
PASSED_MY_VAR: "$VAR_#{rand(1..20)}"
trigger: #{downstream_project.full_path}
YAML
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment