Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stress tests: Fix image tag for multiimage deployments #7498

Merged
merged 1 commit into from
Jan 9, 2024

Conversation

lmolkova
Copy link
Member

@lmolkova lmolkova commented Jan 9, 2024

When multiple docker files are used, one imageTag value was incorrectly applied to all images

Before:

scenarios:
- testScenario: httpget
  image: dockerfiles/java11
  imageBuildDir: ..\..\..\
  .....
- testScenario: httpget
  image: dockerfiles/java21
  imageBuildDir: ..\..\..\

resulted in followoing generated values

scenarios:
- testScenario: httpget
  image: dockerfiles/java11
  imageBuildDir: ..\..\..\
  Scenario: default11get
  imageTag: stresspgs7b6dif73rup6.azurecr.io/limolkova/java-template2/java21:limolkova
- testScenario: httpget
  image: dockerfiles/java21
  imageBuildDir: ..\..\..\
  Scenario: default21get
  imageTag: stresspgs7b6dif73rup6.azurecr.io/limolkova/java-template2/java21:limolkova

Now proper imageTag is generated

@@ -302,7 +302,7 @@ function DeployStressPackage(
}
}
$generatedHelmValues.scenarios = @( foreach ($scenario in $generatedHelmValues.scenarios) {
$dockerPath = if ("image" -notin $scenario) {
$dockerPath = if ("image" -notin $scenario.keys) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$scenarios is a dictionary, and notin checks if item is in the collection, so it never contained image item and did $scenario.imageTag = $imageTag for all scenarios on line 311

@azure-sdk
Copy link
Collaborator

The following pipelines have been queued for testing:
java - template
java - template - tests
js - template
net - template
net - template - tests
python - template
python - template - tests
You can sign off on the approval gate to test the release stage of each pipeline.
See eng/common workflow

Copy link
Member

@RickWinter RickWinter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lmolkova lmolkova enabled auto-merge (squash) January 9, 2024 19:29
Copy link
Member

@benbp benbp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI @ckairen

@benbp
Copy link
Member

benbp commented Jan 9, 2024

@lmolkova I went ahead and merged this since we have a sync process to the other repos I didn't want you to have to worry about.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants