Skip to content

Commit

Permalink
Merge branch 'main' into personal/v-shnarang/bug77964
Browse files Browse the repository at this point in the history
  • Loading branch information
PTaladay authored Dec 6, 2024
2 parents 6ca9e03 + dddf598 commit 47ea959
Show file tree
Hide file tree
Showing 97 changed files with 1,184 additions and 341 deletions.
4 changes: 2 additions & 2 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Testing" Version="$(AspNetPackageVersion)" />
<PackageVersion Include="Microsoft.AspNetCore.TestHost" Version="$(AspNetPackageVersion)" />
<PackageVersion Include="Microsoft.Azure.ContainerRegistry" Version="1.0.0-preview.2" />
<PackageVersion Include="Microsoft.Azure.Cosmos" Version="3.43.1" />
<PackageVersion Include="Microsoft.Azure.Cosmos" Version="3.45.2" />
<PackageVersion Include="Microsoft.Azure.Storage.Blob" Version="11.2.3" />
<PackageVersion Include="Microsoft.Extensions.Configuration.Binder" Version="8.0.1" />
<PackageVersion Include="Microsoft.Extensions.Configuration.CommandLine" Version="8.0.0" />
Expand Down Expand Up @@ -113,7 +113,7 @@
<PackageVersion Include="System.Configuration.ConfigurationManager" Version="8.0.0" />
<PackageVersion Include="System.Data.SqlClient" Version="4.8.6" />
<PackageVersion Include="System.Diagnostics.PerformanceCounter" Version="8.0.0" />
<PackageVersion Include="System.IdentityModel.Tokens.Jwt" Version="8.1.0" />
<PackageVersion Include="System.IdentityModel.Tokens.Jwt" Version="8.1.2" />
<PackageVersion Include="System.IO.FileSystem.AccessControl" Version="5.0.0" />
<PackageVersion Include="System.Net.Http" Version="4.3.4" />
<PackageVersion Include="System.Private.ServiceModel" Version="4.10.3" />
Expand Down
15 changes: 4 additions & 11 deletions Microsoft.Health.Fhir.sln
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Health.Fhir.R4.Te
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Health.Fhir.Azure", "src\Microsoft.Health.Fhir.Azure\Microsoft.Health.Fhir.Azure.csproj", "{6A804695-44D9-4335-B559-9E9A0DAB1102}"
EndProject
Project("{D954291E-2A0B-460D-934E-DC6B0785DB48}") = "Microsoft.Health.Fhir.Shared.Tests.Crucible", "test\Microsoft.Health.Fhir.Shared.Tests.Crucible\Microsoft.Health.Fhir.Shared.Tests.Crucible.shproj", "{218CD980-E236-4EF7-A022-0E94EF844D8F}"
EndProject
Project("{D954291E-2A0B-460D-934E-DC6B0785DB48}") = "Microsoft.Health.Fhir.Shared.Tests.E2E.Common", "test\Microsoft.Health.Fhir.Shared.Tests.E2E.Common\Microsoft.Health.Fhir.Shared.Tests.E2E.Common.shproj", "{0478B687-7105-40F6-A2DC-81057890E944}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Health.Fhir.Azure.UnitTests", "src\Microsoft.Health.Fhir.Azure.UnitTests\Microsoft.Health.Fhir.Azure.UnitTests.csproj", "{4C4701AA-8DE4-44B2-8134-102F040C34F8}"
Expand Down Expand Up @@ -199,11 +197,11 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PerfTester", "tools\PerfTes
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SqlScriptRunner", "tools\SqlScriptRunner\SqlScriptRunner.csproj", "{76C29222-8D35-43A2-89C5-43114D113C10}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Health.Fhir.CosmosDb.Initialization", "src\Microsoft.Health.Fhir.CosmosDb.Initialization\Microsoft.Health.Fhir.CosmosDb.Initialization.csproj", "{10661BC9-01B0-4E35-9751-3B5CE97E25C0}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Health.Fhir.CosmosDb.Initialization", "src\Microsoft.Health.Fhir.CosmosDb.Initialization\Microsoft.Health.Fhir.CosmosDb.Initialization.csproj", "{10661BC9-01B0-4E35-9751-3B5CE97E25C0}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Health.Fhir.CosmosDb.Initialization.UnitTests", "src\Microsoft.Health.Fhir.CosmosDb.Initialization.UnitTests\Microsoft.Health.Fhir.CosmosDb.Initialization.UnitTests.csproj", "{B9AAA11D-8C8C-44C3-AADE-801376EF82F0}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Health.Fhir.CosmosDb.Initialization.UnitTests", "src\Microsoft.Health.Fhir.CosmosDb.Initialization.UnitTests\Microsoft.Health.Fhir.CosmosDb.Initialization.UnitTests.csproj", "{B9AAA11D-8C8C-44C3-AADE-801376EF82F0}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Health.Fhir.CosmosDb.Core", "src\Microsoft.Health.Fhir.CosmosDb.Core\Microsoft.Health.Fhir.CosmosDb.Core.csproj", "{1CD46DC5-6022-4BBE-9A1C-6B13C3CEFC75}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Health.Fhir.CosmosDb.Core", "src\Microsoft.Health.Fhir.CosmosDb.Core\Microsoft.Health.Fhir.CosmosDb.Core.csproj", "{1CD46DC5-6022-4BBE-9A1C-6B13C3CEFC75}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Expand Down Expand Up @@ -521,7 +519,6 @@ Global
{49DA2851-2A19-4969-AE87-94837BACBE7D} = {85F39C13-BC62-49A0-9C06-3BBA724D35ED}
{7F2B9209-2C50-42ED-961B-A09CC8A26A07} = {85F39C13-BC62-49A0-9C06-3BBA724D35ED}
{6A804695-44D9-4335-B559-9E9A0DAB1102} = {7457B218-2651-49B5-BED8-22233889516A}
{218CD980-E236-4EF7-A022-0E94EF844D8F} = {85F39C13-BC62-49A0-9C06-3BBA724D35ED}
{0478B687-7105-40F6-A2DC-81057890E944} = {85F39C13-BC62-49A0-9C06-3BBA724D35ED}
{4C4701AA-8DE4-44B2-8134-102F040C34F8} = {7457B218-2651-49B5-BED8-22233889516A}
{61443024-E60B-4E61-9851-B8D57A8886DC} = {FCD51BAF-BFE5-476F-B562-C9AB36AA9839}
Expand Down Expand Up @@ -580,23 +577,21 @@ Global
{1CD46DC5-6022-4BBE-9A1C-6B13C3CEFC75} = {DC5A2CB1-8995-4D39-97FE-3CE80E892C69}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
RESX_SortFileContentOnSave = True
SolutionGuid = {E370FB31-CF95-47D1-B1E1-863A77973FF8}
RESX_SortFileContentOnSave = True
EndGlobalSection
GlobalSection(SharedMSBuildProjectFiles) = preSolution
test\Microsoft.Health.Fhir.Shared.Tests.E2E.Common\Microsoft.Health.Fhir.Shared.Tests.E2E.Common.projitems*{0478b687-7105-40f6-a2dc-81057890e944}*SharedItemsImports = 13
src\Microsoft.Health.Fhir.Shared.Core\Microsoft.Health.Fhir.Shared.Core.projitems*{070759a9-51d9-4967-8651-39cca8288c93}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Tests\Microsoft.Health.Fhir.Shared.Tests.projitems*{1495bba7-07b8-47ca-b2ed-511003b57667}*SharedItemsImports = 13
src\Microsoft.Health.Fhir.Shared.Core.UnitTests\Microsoft.Health.Fhir.Shared.Core.UnitTests.projitems*{1b944b8a-54f2-4af3-a38a-ca7f1ab5c618}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Tests\Microsoft.Health.Fhir.Shared.Tests.projitems*{1b944b8a-54f2-4af3-a38a-ca7f1ab5c618}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.Crucible\Microsoft.Health.Fhir.Shared.Tests.Crucible.projitems*{218cd980-e236-4ef7-a022-0e94ef844d8f}*SharedItemsImports = 13
src\Microsoft.Health.Fhir.Shared.Core\Microsoft.Health.Fhir.Shared.Core.projitems*{28ee5d89-e439-46e1-bbe0-5ae986d409c7}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Core\Microsoft.Health.Fhir.Shared.Core.projitems*{295745e2-4dd3-4aab-908d-b3dee976bf0e}*SharedItemsImports = 13
src\Microsoft.Health.Fhir.Shared.Core.UnitTests\Microsoft.Health.Fhir.Shared.Core.UnitTests.projitems*{443ecda6-e05b-4bb0-90d9-441fb77cd919}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Tests\Microsoft.Health.Fhir.Shared.Tests.projitems*{443ecda6-e05b-4bb0-90d9-441fb77cd919}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Client\Microsoft.Health.Fhir.Shared.Client.projitems*{4640d17c-7229-4d90-a330-0423dfc3ffc5}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Tests\Microsoft.Health.Fhir.Shared.Tests.projitems*{49da2851-2a19-4969-ae87-94837bacbe7d}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.Crucible\Microsoft.Health.Fhir.Shared.Tests.Crucible.projitems*{49da2851-2a19-4969-ae87-94837bacbe7d}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.E2E.Common\Microsoft.Health.Fhir.Shared.Tests.E2E.Common.projitems*{49da2851-2a19-4969-ae87-94837bacbe7d}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.E2E\Microsoft.Health.Fhir.Shared.Tests.E2E.projitems*{49da2851-2a19-4969-ae87-94837bacbe7d}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Api\Microsoft.Health.Fhir.Shared.Api.projitems*{4b4abb04-42ba-461c-a202-e480a2ae538e}*SharedItemsImports = 13
Expand All @@ -615,7 +610,6 @@ Global
src\Microsoft.Health.Fhir.Shared.Web.UnitTests\Microsoft.Health.Fhir.Shared.Web.UnitTests.projitems*{73bc4365-2bfb-41c7-b0b1-610059f967ac}*SharedItemsImports = 13
src\Microsoft.Health.Fhir.Shared.Client\Microsoft.Health.Fhir.Shared.Client.projitems*{743ea25c-a6f5-4b41-bc56-69d9a89386a3}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Tests\Microsoft.Health.Fhir.Shared.Tests.projitems*{7f2b9209-2c50-42ed-961b-a09cc8a26a07}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.Crucible\Microsoft.Health.Fhir.Shared.Tests.Crucible.projitems*{7f2b9209-2c50-42ed-961b-a09cc8a26a07}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.E2E.Common\Microsoft.Health.Fhir.Shared.Tests.E2E.Common.projitems*{7f2b9209-2c50-42ed-961b-a09cc8a26a07}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.E2E\Microsoft.Health.Fhir.Shared.Tests.E2E.projitems*{7f2b9209-2c50-42ed-961b-a09cc8a26a07}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Api\Microsoft.Health.Fhir.Shared.Api.projitems*{81a3b383-1560-45e1-9540-9143060243dd}*SharedItemsImports = 5
Expand All @@ -630,7 +624,6 @@ Global
src\Microsoft.Health.Fhir.Shared.Core\Microsoft.Health.Fhir.Shared.Core.projitems*{a0320ae9-3f87-44a3-8263-5af7e00085d4}*SharedItemsImports = 5
src\Microsoft.Health.Fhir.Shared.Client\Microsoft.Health.Fhir.Shared.Client.projitems*{a4c416db-67b9-48ae-bc67-96bfced1bcf5}*SharedItemsImports = 13
src\Microsoft.Health.Fhir.Shared.Tests\Microsoft.Health.Fhir.Shared.Tests.projitems*{a5ded132-32b1-4804-95f5-ebc6092ec8ae}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.Crucible\Microsoft.Health.Fhir.Shared.Tests.Crucible.projitems*{a5ded132-32b1-4804-95f5-ebc6092ec8ae}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.E2E.Common\Microsoft.Health.Fhir.Shared.Tests.E2E.Common.projitems*{a5ded132-32b1-4804-95f5-ebc6092ec8ae}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.E2E\Microsoft.Health.Fhir.Shared.Tests.E2E.projitems*{a5ded132-32b1-4804-95f5-ebc6092ec8ae}*SharedItemsImports = 5
test\Microsoft.Health.Fhir.Shared.Tests.E2E\Microsoft.Health.Fhir.Shared.Tests.E2E.projitems*{a898cc57-69d0-4454-bb70-784c138a05bf}*SharedItemsImports = 13
Expand Down
21 changes: 17 additions & 4 deletions build/ci-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,18 @@ stages:
- template: ./jobs/build.yml
parameters:
targetBuildFramework: 'net6.0'

- stage: BuildArtifacts
displayName: 'Build artifacts'
dependsOn:
- UpdateVersion
variables:
assemblySemVer: $[stageDependencies.UpdateVersion.Semver.outputs['SetVariablesFromGitVersion.assemblySemVer']]
assemblySemFileVer: $[stageDependencies.UpdateVersion.Semver.outputs['SetVariablesFromGitVersion.assemblySemFileVer']]
informationalVersion: $[stageDependencies.UpdateVersion.Semver.outputs['SetVariablesFromGitVersion.informationalVersion']]
majorMinorPatch: $[stageDependencies.UpdateVersion.Semver.outputs['SetVariablesFromGitVersion.majorMinorPatch']]
nuGetVersion: $[stageDependencies.UpdateVersion.Semver.outputs['SetVariablesFromGitVersion.nuGetVersion']]
jobs:
- job: Linux_BuildAndPackage
pool:
name: '$(DefaultLinuxPool)'
Expand All @@ -99,6 +111,7 @@ stages:
displayName: 'Run Security Analysis and Validate'
dependsOn:
- BuildUnitTests
- BuildArtifacts
jobs:
- job: Guardian
pool:
Expand Down Expand Up @@ -147,7 +160,7 @@ stages:
- stage: testStu3
displayName: 'Run Stu3 Tests'
dependsOn:
- BuildUnitTests
- BuildArtifacts
- redeployStu3
- redeployStu3Sql
jobs:
Expand Down Expand Up @@ -186,7 +199,7 @@ stages:
- stage: testR4
displayName: 'Run R4 Tests'
dependsOn:
- BuildUnitTests
- BuildArtifacts
- redeployR4
- redeployR4Sql
jobs:
Expand Down Expand Up @@ -225,7 +238,7 @@ stages:
- stage: testR4B
displayName: 'Run R4B Tests'
dependsOn:
- BuildUnitTests
- BuildArtifacts
- redeployR4B
- redeployR4BSql
jobs:
Expand Down Expand Up @@ -264,7 +277,7 @@ stages:
- stage: testR5
displayName: 'Run R5 Tests'
dependsOn:
- BuildUnitTests
- BuildArtifacts
- redeployR5
- redeployR5Sql
jobs:
Expand Down
2 changes: 1 addition & 1 deletion build/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ COPY . .
RUN dotnet publish /repo/src/Microsoft.Health.Fhir.${FHIR_VERSION}.Web/Microsoft.Health.Fhir.${FHIR_VERSION}.Web.csproj -o "/build" --no-restore -p:AssemblyVersion="${ASSEMBLY_VER}" -p:FileVersion="${ASSEMBLY_VER}" -p:Version="${ASSEMBLY_VER}" -f net8.0 -a $TARGETARCH

# Implicitly uses the target platform for the runtime image.
FROM mcr.microsoft.com/dotnet/aspnet:8.0.10-cbl-mariner2.0 AS runtime
FROM mcr.microsoft.com/dotnet/aspnet:8.0.11-cbl-mariner2.0 AS runtime

ARG FHIR_VERSION

Expand Down
14 changes: 8 additions & 6 deletions build/jobs/analyze.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,12 +89,14 @@ steps:
Path: '$(Build.SourcesDirectory)'
ToolVersion: Latest

- task: Trivy@1
displayName: 'Run Trivy'
inputs:
Target: '$(Build.SourcesDirectory)/build/docker'
Severities: all
VulTypes: all
## Currently removed due to too many requests issue: https://github.com/aquasecurity/trivy-action/issues/430
## User story to address restoring this: 132160
#- task: Trivy@1
# displayName: 'Run Trivy'
# inputs:
# Target: '$(Build.SourcesDirectory)/build/docker'
# Severities: all
# VulTypes: all

- task: PSScriptAnalyzer@1
displayName: 'Run PSScriptAnalyzer'
Expand Down
1 change: 1 addition & 0 deletions build/jobs/docker-build-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
scriptType: 'bash'
scriptLocation: 'inlineScript'
inlineScript: |
docker pull mirror.gcr.io/moby/buildkit:buildx-stable-1
TAG="$(azureContainerRegistry)/${{parameters.version}}_fhir-server:${{parameters.tag}}"
az acr login --name $(azureContainerRegistryName)
docker buildx create --name fhir-multi-platform --platform ${{parameters.buildPlatform}} --use --bootstrap
Expand Down
3 changes: 3 additions & 0 deletions docs/DefaultDeployment.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ We recommend starting with the SQL deployment as it offers the most features. Ho
Note that when you deploy from our templates, it is set to deploy with $export enabled. As part of the export setup, a storage account is automatically created along with roles. The creation of this storage account and roles requires that you have contributor access at the subscription level. If the person deploying does not have contributor access at the subscription level, the deployment will fail. To deploy successfully in this scenario, you can deploy with export set to false. If you need to use export, it can be configured to true after deployment by someone with contributor access at the subscription level. It takes a few more steps as someone will need to create and link the storage account (it won’t automatically get created) but from there it will work exactly as if you had set it to true at provisioning.

To deploy the backend SQL Server, Azure Web App, and FHIR server code, use the buttons below to deploy through the Azure Portal. If you would like to protect the FHIR API with token authorization, you will need to supply application registration details as described above.
###### NOTE
>If you select a SQL database deployment with the Schema Update set to TOOL, you must run the SQL migration tool immediately after the deployment completes successfully.<br>
Detailed information about this tool is provided [here](SchemaMigrationTool.md).

The FHIR server can be deployed using all free Azure resources. When deploying select 'F1' as the App Service Plan Sku, 'Yes' to use the Cosmos DB Free Tier, and FhirServerCosmosDB as the Solution Type. The free app service plan and Cosmos Db account have restrictions that can be seen on their respective doc pages: [App Service plan overview](https://docs.microsoft.com/en-us/azure/app-service/overview-hosting-plans), [Cosmos DB free tier](https://docs.microsoft.com/en-us/azure/cosmos-db/optimize-dev-test#azure-cosmos-db-free-tier)

Expand Down
61 changes: 61 additions & 0 deletions docs/rest/FhirPatchRequests.http
Original file line number Diff line number Diff line change
Expand Up @@ -337,4 +337,65 @@ Authorization: Bearer {{bearer.response.body.access_token}}
]
}
]
}

### Add a security tag. This will always add the elements to the end of the array if the array exists or not.
PATCH https://{{hostname}}/Patient/{{patient.response.body.id}}
content-type: application/fhir+json
Authorization: Bearer {{bearer.response.body.access_token}}

{
"resourceType": "Parameters",
"parameter": [
{
"name": "operation",
"part": [
{
"name": "type",
"valueCode": "add"
},
{
"name": "path",
"valueString": "Patient.meta"
},
{
"name": "name",
"valueString": "security"
},
{
"name": "value",
"valueCoding": {
"system": "http://example.org/security-system",
"code": "SECURITY_TAG_CODE",
"display": "New Security Tag Display"
}
}
]
},
{
"name": "operation",
"part": [
{
"name": "type",
"valueCode": "add"
},
{
"name": "path",
"valueString": "Patient.meta"
},
{
"name": "name",
"valueString": "security"
},
{
"name": "value",
"valueCoding": {
"system": "http://example.org/security-system",
"code": "NEW_SECURITY_TAG_CODE",
"display": "New Security Tag Display"
}
}
]
}
]
}
39 changes: 38 additions & 1 deletion docs/rest/JsonPatchRequests.http
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ Authorization: Bearer {{bearer.response.body.access_token}}
}

### Conditional Patch
PATCH {{fhirurl}}/Patient?identifier=1032704
PATCH {{hostname}}/Patient?identifier=1032704
content-type: application/json-patch+json
Authorization: Bearer {{bearer.response.body.access_token}}

Expand All @@ -202,3 +202,40 @@ Authorization: Bearer {{bearer.response.body.access_token}}
}
}
]

### Add a security tag. Replaces entire array if it exists
PATCH https://{{hostname}}/Patient/{{patient.response.body.id}}
content-type: application/json-patch+json
Authorization: Bearer {{bearer.response.body.access_token}}

[
{
"op": "add",
"path": "/meta/security",
"value": [
{
"system": "http://example.org/security-system",
"code": "SECURITY_TAG_CODE",
"display": "Security Tag Display"
}
]
}
]

### Add a security tag. Array must already exist.
# You cannot use JSON patch to add when you don't know if the array exists. Use FHIR Patch in this scenario.
PATCH https://{{hostname}}/Patient/{{patient.response.body.id}}
content-type: application/json-patch+json
Authorization: Bearer {{bearer.response.body.access_token}}

[
{
"op": "add",
"path": "/meta/security/-",
"value": {
"system": "http://example.org/security-system",
"code": "NEW_SECURITY_TAG_CODE",
"display": "New Security Tag Display"
}
}
]
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public async Task Invoke(HttpContext context)
&& request.Method == "POST"
&& request.Path.Value.EndsWith(KnownRoutes.Search, System.StringComparison.OrdinalIgnoreCase))
{
if (request.ContentType is null || request.ContentType == "application/x-www-form-urlencoded")
if (request.ContentType is null || request.HasFormContentType)
{
if (request.HasFormContentType)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,9 @@ private ContainerRegistryInfo GetTestContainerRegistryInfo()
{
var containerRegistry = new ContainerRegistryInfo
{
Server = Environment.GetEnvironmentVariable("TestContainerRegistryServer"),
Username = Environment.GetEnvironmentVariable("TestContainerRegistryServer")?.Split('.')[0],
Password = Environment.GetEnvironmentVariable("TestContainerRegistryPassword"),
Server = EnvironmentVariables.GetEnvironmentVariable(KnownEnvironmentVariableNames.TestContainerRegistryServer),
Username = EnvironmentVariables.GetEnvironmentVariable(KnownEnvironmentVariableNames.TestContainerRegistryServer)?.Split('.')[0],
Password = EnvironmentVariables.GetEnvironmentVariable(KnownEnvironmentVariableNames.TestContainerRegistryPassword),
};

if (string.IsNullOrEmpty(containerRegistry.Server) || string.IsNullOrEmpty(containerRegistry.Password))
Expand Down
Loading

0 comments on commit 47ea959

Please sign in to comment.