Commit Graph

141 Commits

Author SHA1 Message Date
Azure SDK Bot
d9dc195971
Remove extraneous unconditional bicep invocation (#6799)
Fails if you don't have `bicep` installed but do have `az bicep` and was unnecessary since the check below it did it anyway.

Co-authored-by: Heath Stewart <heaths@microsoft.com>
2025-10-21 14:23:17 -07:00
Azure SDK Bot
bc178b1f98
Source user ID from graph api in TME (#6720)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-08-29 16:15:45 -04:00
Azure SDK Bot
236acb5edd
Throw error if deprecated parameter -UserAuth is passed (#6691)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-08-07 11:17:09 -07:00
Azure SDK Bot
28a55c5161
Source user object id directly instead of with graph (#6687)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-08-06 12:19:05 -07:00
Azure SDK Bot
093d25d839
Make sure we print env vars for JSON ARM templates (#6686)
Fixes #10734

Co-authored-by: Heath Stewart <heaths@microsoft.com>
2025-08-05 15:21:05 -07:00
Azure SDK Bot
18a1d27d33
Pass TestResourcesDirectory from deploy-test-resources.yml to New-TestResources.ps1 (#6646)
Co-authored-by: Patrick Hallisey <pahallis@microsoft.com>
2025-06-26 14:36:01 -07:00
Azure SDK Bot
6a71677c9e
Use Path.Combine for create directory (#6630)
Path.Combine will allow for fully qualified paths to override the combination. For example `Path.Combine("a","b","c:\test")` will resolve to `c:\test'. We have depended on such behavior in a few places like d66b5160f2/eng/pipelines/templates/steps/smoke-test-steps.yml (L99) so I'm reverting back to Path.Combine.

Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com>
2025-06-18 08:59:02 -07:00
Azure SDK Bot
77eee12717
Support az bicep build in New-TestResources (#6572)
Co-authored-by: Patrick Hallisey <pahallis@microsoft.com>
2025-05-14 17:38:51 -07:00
Azure SDK Bot
c61528188c
Sync eng/common directory with azure-sdk-tools for PR 10532 (#6571)
* Allow for empty serviceDirectory in deploy-test-resources

* Revert some unintentional changes

* Restore missing comment

---------

Co-authored-by: Patrick Hallisey <pahallis@microsoft.com>
2025-05-14 12:45:38 -07:00
Azure SDK Bot
438ad5d6f8
Sync eng/common directory with azure-sdk-tools for PR 10579 (#6564)
* Support writing .env files from Test Resources

If a language repo opts into it *and* if a `test-resources.bicep` file exists and lints clean of writing secrets *and* if the `.env` file is gitignore'd, write a `.env` file next to `test-resources.bicep`.

* Resolve PR feedback

* Pass -Force for . hidden files on non-Windows

---------

Co-authored-by: Heath Stewart <heaths@microsoft.com>
2025-05-09 21:51:43 -07:00
Azure SDK Bot
9ae114d856
Set the resource group prefix after we get the tenantId (#6543)
Given we are using the tenantId to determine to add the prefix or not we need to make sure we have it set before we check it. For the pipelines it is set at the script calling time so it was working there but for some local scenarios it is not set yet, so we need to do it a little later in the script.

Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com>
2025-04-28 12:39:49 -07:00
Azure SDK Bot
dd65910814
Add AdditionalParameters global variable to dynamic post script (#6506)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-04-03 19:00:18 -04:00
Azure SDK Bot
c914c0933f
Import Az powershell module in self contained post script task (#6484)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-03-26 15:25:31 -07:00
Azure SDK Bot
bf36db827f
Add option to create self contained test resources post script (#6476)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-03-25 18:24:20 -07:00
Azure SDK Bot
038457a155
Add resource prefix for safe secret standard alerts (#6458)
Add the prefix to identify RGs that we are creating in our TME
tenant to identify them as potentially using local auth and violating
our safe secret standards.

Co-authored-by: Wes Haggard <Wes.Haggard@microsoft.com>
2025-03-13 10:59:53 -07:00
Azure SDK Bot
23df1f63e5
Sync eng/common directory with azure-sdk-tools for PR 10013 (#6455)
* Fix supportsSafeSecretStandard flag

* Update eng/common/TestResources/New-TestResources.ps1

---------

Co-authored-by: Deyaaeldeen Almahallawi <dealmaha@microsoft.com>
Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com>
2025-03-10 09:50:59 -07:00
Azure SDK Bot
c378e69d0d
Add well known tenant IDs and TME status (#6438)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-03-06 11:42:41 -08:00
Azure SDK Bot
ab5a01b7cc
chmod +x TestResources scripts (#6421)
Make them executable in bash et. al. without starting separate shell.

Co-authored-by: Heath Stewart <heaths@microsoft.com>
2025-02-14 10:07:38 -08:00
Azure SDK Bot
d404aba845
Print clickable link to terminal (#6399)
Co-authored-by: Heath Stewart <heaths@microsoft.com>
2025-02-06 13:24:39 -08:00
Azure SDK Bot
9a1c237bcd
Flip supportsSafeSecretStandard boolean condition (#6395)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-02-05 16:27:27 -08:00
Azure SDK Bot
2dccdce3a0
Sync eng/common directory with azure-sdk-tools for PR 9745 (#6390)
* Pass arm template parameter for TME context

* Use supportsSafeSecretStandard parameter instead

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-02-04 14:05:16 -08:00
Azure SDK Bot
a9083d489b
Add fallback user id lookup for test resource deployment (#6375)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-01-28 11:44:31 -08:00
Azure SDK Bot
938222b018
Sync eng/common directory with azure-sdk-tools for PR 9529 (#6305)
* Use -Mail for test resources local user lookup to support TME

* Auto-select TME subscription based on user context

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2025-01-16 10:42:58 -08:00
Azure SDK Bot
0e699e4c7a
Sync eng/common directory with azure-sdk-tools for PR 9229 (#6115)
* Remove default sub config sub-config-azure-cloud-test-resources

We no longer want to default the configuration and instead
default from the service connection which had the info we need.

* Fix quoting

---------

Co-authored-by: Wes Haggard <Wes.Haggard@microsoft.com>
2024-10-21 18:20:35 -07:00
Azure SDK Bot
f4eea46002
Move perf pipelines to TME subscription (#6113)
Co-authored-by: Wes Haggard <Wes.Haggard@microsoft.com>
2024-10-21 12:56:43 -07:00
Azure SDK Bot
027f31302a
Set resource group env variable early so remove always works (#6106)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-10-16 15:25:24 -07:00
Azure SDK Bot
9b4417e38f
Use equality function check for persist oidc token step (#6084)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-10-08 15:37:18 -07:00
Azure SDK Bot
4b913e073e
Persist oidc env vars in deploy template (#6079)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-10-08 11:59:21 -07:00
Azure SDK Bot
519e208a00
Need to add environment to subscription configuration (#6068)
Co-authored-by: Wes Haggard <Wes.Haggard@microsoft.com>
2024-10-04 13:16:42 -07:00
Azure SDK Bot
54e5e22b1a
Sync eng/common directory with azure-sdk-tools for PR 9092 (#6061)
* Export the subscription data from the service connection

* Update deploy-test-resources.yml

---------

Co-authored-by: Wes Haggard <Wes.Haggard@microsoft.com>
Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com>
2024-10-03 15:11:09 -07:00
Azure SDK Bot
90bd17c5b4
Update New-TestResources.ps1 to add quotes around shell envvar (#6050)
Co-authored-by: swathipil <swathip@microsoft.com>
2024-10-02 13:14:52 -07:00
Azure SDK Bot
cfcfac67f7
Sync eng/common directory with azure-sdk-tools for PR 8902 (#5965)
* Add descriptive error when variable groups are not added to pipeline

* Add emoji to deploy step title to make it easier to find

* Move yaml json checking into powershell script

* Fix base sub config empty/string checking

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-09-10 17:04:41 -04:00
Azure SDK Bot
65e2547763
Sync eng/common directory with azure-sdk-tools for PR 8760 (#5874)
* Do not mark values as secret that are from git-hosted sub config files

* Simplify sub config build yaml

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-08-06 12:54:24 -07:00
Azure SDK Bot
7176808c7f
Add remaining preview/sov cloud sub configs to common dir (#5844)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-07-24 12:38:54 -07:00
Azure SDK Bot
ae14b41e8e
Sync eng/common directory with azure-sdk-tools for PR 8598 (#5777)
* Set storage account test resources to disable blob public access

* Skip adding network rules to storage accounts that don't need them during cleanup

* Add succeeded check to set pipeline subnet info step

* Disable network firewall by default in resource creation/removal

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-07-12 17:15:32 -04:00
Azure SDK Bot
bc547c4f4c
Sync eng/common directory with azure-sdk-tools for PR 8558 (#5764)
* Support storage network access and worm removal in remove test resources script

* Move storage network access script to common resource helpers file

* Improve storage container deletion resilience

* Plumb through pool variable to live test cleanup template

* Add sleep for network rule application

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-07-08 17:56:18 -04:00
Azure SDK Bot
5251c27034
Sync eng/common directory with azure-sdk-tools for PR 8516 (#5752)
* Ensure subConfigFiles is not an empty string

* Skip instances where $file is an empty string

---------

Co-authored-by: Daniel Jurek <djurek@microsoft.com>
2024-07-03 17:51:11 -04:00
Azure SDK Bot
a7ce5b43c3
Sync eng/common directory with azure-sdk-tools for PR 8528 (#5755)
* Fix default value for env vars in build-test-resource-config template

* Add empty pool condition

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-07-03 14:23:56 -04:00
Azure SDK Bot
88bb72c045
Sync eng/common directory with azure-sdk-tools for PR 8371 (#5685)
* Restrict live test storage account access to client IP

* Add storage pools to test resources vnet allowlist

* Use pool subnet map to reduce number of subnets added to live test resources

* snap

* Add test resource parameter to add ip ranges to storage firewall

* Validate and update ip firewall rules

* Get pool subnet using separate workload identity

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-07-01 15:08:16 -04:00
Azure SDK Bot
2f74d85edb
Sync eng/common directory with azure-sdk-tools for PR 8422 (#5712)
* Merge subscription configuration file values with the supplied subscription config

* Bring forward working parts

* Collapse into a single task

* SubConfig-Helpers.ps1 changes

* Update remove-test-resources.yml

---------

Co-authored-by: Daniel Jurek <djurek@microsoft.com>
2024-06-17 16:27:00 -07:00
Azure SDK Bot
c4a395e0b9
Pass pipeline vnet to live test arm templates (#5724)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-06-17 18:07:39 -04:00
Azure SDK Bot
3635e2064a
Sync eng/common directory with azure-sdk-tools for PR 8377 (#5690)
* Plumb env vars through deploy test resources

* Update eng/common/TestResources/deploy-test-resources.yml

Co-authored-by: Daniel Jurek <djurek@microsoft.com>

* Update eng/common/TestResources/deploy-test-resources.yml

Co-authored-by: Daniel Jurek <djurek@microsoft.com>

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
Co-authored-by: Daniel Jurek <djurek@microsoft.com>
2024-06-06 19:11:02 -04:00
Azure SDK Bot
1b8d54e396
Sync eng/common directory with azure-sdk-tools for PR 8319 (#5653)
* Add static file secret-less sub-config support

* Review feedback: if/else

* http -> https

* Update eng/common/TestResources/deploy-test-resources.yml

* Space cleanup

* Add AzurePublicMsft.json

* Remove EnvironmentVariables

---------

Co-authored-by: Daniel Jurek <djurek@microsoft.com>
Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com>
2024-05-28 14:43:46 -07:00
Azure SDK Bot
c79967ef99
Sync eng/common directory with azure-sdk-tools for PR 8249 (#5616)
* Add support for Federated Auth to test resources scripts

* Default -- UseFederatedAuth: false

* Clear secrets if FederatedAuth is set

* Template conditions use AzurePowerShell only when a service connection is needed

* Review feedback and pair with Ben

* Update docs

* http:// -> https://

---------

Co-authored-by: Daniel Jurek <djurek@microsoft.com>
2024-05-15 14:17:16 -07:00
Azure SDK Bot
87036bc05e
TestResources - Bubble up errors in Retry with pipe statements (#5413)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-03-06 16:13:16 -08:00
Azure SDK Bot
f348242546
Add stress test arm/bicep template prefix to New-TestResources ResourceType set (#5340)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2024-02-09 18:11:07 -05:00
Azure SDK Bot
dffa3edb2a
Sync eng/common directory with azure-sdk-tools for PR 7584 (#5294)
* Fix role assignment for user auth

* PR fb

* Apply suggestions from code review

Co-authored-by: Heath Stewart <heaths@outlook.com>

---------

Co-authored-by: jolov <jolov@microsoft.com>
Co-authored-by: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com>
Co-authored-by: Heath Stewart <heaths@outlook.com>
2024-01-25 14:52:29 -08:00
Azure SDK Bot
85f4835e96
Sync eng/common directory with azure-sdk-tools for PR 7580 (#5292)
* Support creating resources with user auth

* Log warning if TestApplicationId is set

* missing space

* regenerate md file

* Rename

* Update link

---------

Co-authored-by: jolov <jolov@microsoft.com>
2024-01-24 15:38:17 -08:00
Azure SDK Bot
eccfeb4be0
Sync eng/common directory with azure-sdk-tools for PR 7310 (#5173)
* Force capitalize all deployment/env outputs in live test

* Update eng/common/TestResources/New-TestResources.ps1

Co-authored-by: Heath Stewart <heaths@outlook.com>

---------

Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
Co-authored-by: Heath Stewart <heaths@outlook.com>
2023-11-20 11:02:56 -08:00
Azure SDK Bot
21978a69d8
Fix update test resources tagging when tags are empty. Bump max limit (#5048)
Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com>
2023-10-19 15:58:56 -07:00