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

Fix Function App unable to start #91

Merged
merged 3 commits into from
Mar 4, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 10 additions & 8 deletions deploy/templates/consumption-azuredeploy.json
Original file line number Diff line number Diff line change
Expand Up @@ -401,30 +401,32 @@
},
{
"type": "Microsoft.EventHub/namespaces/eventhubs/providers/roleAssignments",
"apiVersion": "2018-01-01-preview",
"apiVersion": "2018-07-01",
"name": "[concat(variables('devicedata_eventhub_name'), '/Microsoft.Authorization/', guid(uniqueString(variables('devicedata_eventhub_name'))))]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', variables('app_service_name'))]",
"[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'devicedata')]"
],
"properties": {
"roleDefinitionId": "[variables('receiver_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'devicedata')]"
"roleDefinitionId": "[variables('receiver_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'devicedata')]",
"principalType": "ServicePrincipal"
}
},
{
"type": "Microsoft.EventHub/namespaces/eventhubs/providers/roleAssignments",
"apiVersion": "2018-01-01-preview",
"apiVersion": "2018-07-01",
"name": "[concat(variables('normalizeddata_eventhub_name'), '/Microsoft.Authorization/', guid(uniqueString(variables('normalizeddata_eventhub_name'))))]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', variables('app_service_name'))]",
"[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'normalizeddata')]"
],
"properties": {
"roleDefinitionId": "[variables('sender_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'normalizeddata')]"
"roleDefinitionId": "[variables('sender_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'normalizeddata')]",
"principalType": "ServicePrincipal"
}
},
{
Expand Down
18 changes: 10 additions & 8 deletions deploy/templates/default-azuredeploy.json
Original file line number Diff line number Diff line change
Expand Up @@ -422,30 +422,32 @@
},
{
"type": "Microsoft.EventHub/namespaces/eventhubs/providers/roleAssignments",
"apiVersion": "2018-01-01-preview",
"apiVersion": "2018-07-01",
"name": "[concat(variables('devicedata_eventhub_name'), '/Microsoft.Authorization/', guid(uniqueString(variables('devicedata_eventhub_name'))))]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', variables('app_service_name'))]",
"[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'devicedata')]"
],
"properties": {
"roleDefinitionId": "[variables('receiver_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'devicedata')]"
"roleDefinitionId": "[variables('receiver_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'devicedata')]",
"principalType": "ServicePrincipal"
}
},
{
"type": "Microsoft.EventHub/namespaces/eventhubs/providers/roleAssignments",
"apiVersion": "2018-01-01-preview",
"apiVersion": "2018-07-01",
"name": "[concat(variables('normalizeddata_eventhub_name'), '/Microsoft.Authorization/', guid(uniqueString(variables('normalizeddata_eventhub_name'))))]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', variables('app_service_name'))]",
"[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'normalizeddata')]"
],
"properties": {
"roleDefinitionId": "[variables('sender_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'normalizeddata')]"
"roleDefinitionId": "[variables('sender_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'normalizeddata')]",
"principalType": "ServicePrincipal"
}
},
{
Expand Down
10 changes: 6 additions & 4 deletions deploy/templates/managed-identity-azuredeploy.json
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,7 @@
},
{
"type": "Microsoft.EventHub/namespaces/eventhubs/providers/roleAssignments",
"apiVersion": "2018-01-01-preview",
"apiVersion": "2018-07-01",
"name": "[concat(variables('devicedata_eventhub_name'), '/Microsoft.Authorization/', guid(uniqueString(variables('devicedata_eventhub_name'))))]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', variables('app_service_name'))]",
Expand All @@ -418,12 +418,13 @@
"properties": {
"roleDefinitionId": "[variables('receiver_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), variables('devicedata_name'))]"
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), variables('devicedata_name'))]",
"principalType": "ServicePrincipal"
}
},
{
"type": "Microsoft.EventHub/namespaces/eventhubs/providers/roleAssignments",
"apiVersion": "2018-01-01-preview",
"apiVersion": "2018-07-01",
"name": "[concat(variables('normalizeddata_eventhub_name'), '/Microsoft.Authorization/', guid(uniqueString(variables('normalizeddata_eventhub_name'))))]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', variables('app_service_name'))]",
Expand All @@ -432,7 +433,8 @@
"properties": {
"roleDefinitionId": "[variables('sender_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), variables('normalizeddata_name'))]"
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), variables('normalizeddata_name'))]",
"principalType": "ServicePrincipal"
}
},
{
Expand Down
18 changes: 10 additions & 8 deletions deploy/templates/premium-azuredeploy.json
Original file line number Diff line number Diff line change
Expand Up @@ -401,30 +401,32 @@
},
{
"type": "Microsoft.EventHub/namespaces/eventhubs/providers/roleAssignments",
"apiVersion": "2018-01-01-preview",
"apiVersion": "2018-07-01",
"name": "[concat(variables('devicedata_eventhub_name'), '/Microsoft.Authorization/', guid(uniqueString(variables('devicedata_eventhub_name'))))]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', variables('app_service_name'))]",
"[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'devicedata')]"
],
"properties": {
"roleDefinitionId": "[variables('receiver_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'devicedata')]"
"roleDefinitionId": "[variables('receiver_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'devicedata')]",
"principalType": "ServicePrincipal"
}
},
{
"type": "Microsoft.EventHub/namespaces/eventhubs/providers/roleAssignments",
"apiVersion": "2018-01-01-preview",
"apiVersion": "2018-07-01",
"name": "[concat(variables('normalizeddata_eventhub_name'), '/Microsoft.Authorization/', guid(uniqueString(variables('normalizeddata_eventhub_name'))))]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', variables('app_service_name'))]",
"[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'normalizeddata')]"
],
"properties": {
"roleDefinitionId": "[variables('sender_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'normalizeddata')]"
"roleDefinitionId": "[variables('sender_role')]",
"principalId": "[reference(variables('app_service_resource_id'), '2015-08-01', 'Full').Identity.principalId]",
"scope": "[resourceId('Microsoft.EventHub/namespaces/eventhubs', variables('eventhub_namespace_name'), 'normalizeddata')]",
"principalType": "ServicePrincipal"
}
},
{
Expand Down
6 changes: 3 additions & 3 deletions src/console/Microsoft.Health.Fhir.Ingest.Console.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Storage" Version="4.0.3" />
<PackageReference Include="Microsoft.Extensions.Hosting" Version="2.2.0" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.8.0">
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Storage" Version="4.0.4" />
<PackageReference Include="Microsoft.Extensions.Hosting" Version="3.1.12" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.9.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,17 @@
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Azure.EventHubs.Processor" Version="4.3.1" />
<PackageReference Include="Microsoft.Azure.WebJobs" Version="3.0.23" />
<PackageReference Include="Microsoft.Azure.WebJobs" Version="3.0.25" />
<PackageReference Include="Microsoft.AspNetCore.Hosting" Version="2.2.7" />
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.EventHubs" Version="4.2.0" />
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Http" Version="3.0.2" />
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Storage" Version="4.0.3" />
<PackageReference Include="Microsoft.Azure.WebJobs.Logging.ApplicationInsights" Version="3.0.23" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="2.2.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.AzureKeyVault" Version="2.2.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="2.2.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.UserSecrets" Version="2.2.0" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.8.0">
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Http" Version="3.0.12" />
<PackageReference Include="Microsoft.Azure.WebJobs.Extensions.Storage" Version="4.0.4" />
<PackageReference Include="Microsoft.Azure.WebJobs.Logging.ApplicationInsights" Version="3.0.25" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="3.1.12" />
<PackageReference Include="Microsoft.Extensions.Configuration.AzureKeyVault" Version="3.1.12" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="3.1.12" />
<PackageReference Include="Microsoft.Extensions.Configuration.UserSecrets" Version="3.1.12" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.9.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand All @@ -41,7 +41,6 @@
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Text.RegularExpressions" Version="4.3.1" />
<PackageReference Include="xunit" Version="2.4.1" />
</ItemGroup>
<ItemGroup>
<None Update="host.json">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,18 @@
<ItemGroup>
<PackageReference Include="Azure.Storage.Blobs" Version="12.8.0" />
<PackageReference Include="Ensure.That" Version="9.2.0" />
<PackageReference Include="Microsoft.Extensions.Options" Version="5.0.0" />
Copy link
Member Author

Choose a reason for hiding this comment

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

This was the specific package upgrade in the previous update causing the function app to crash on Azure App Services.

<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.8.0">
<PackageReference Include="Microsoft.Extensions.Options" Version="3.1.12" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.9.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="StyleCop.Analyzers" Version="1.1.118">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Azure.Core" Version="1.8.1" />
<PackageReference Include="Azure.Core" Version="1.9.0" />
<PackageReference Include="Azure.Identity" Version="1.3.0" />
<PackageReference Include="System.Text.RegularExpressions" Version="4.3.1" />
<PackageReference Include="System.Threading.Tasks.Dataflow" Version="4.9.0" />
<PackageReference Include="xunit" Version="2.4.1" />
</ItemGroup>
</Project>
14 changes: 5 additions & 9 deletions src/lib/Microsoft.Health.Events/Microsoft.Health.Events.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,15 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="Azure.Identity" Version="1.3.0" />
<PackageReference Include="Azure.Messaging.EventHubs" Version="5.2.0" />
<PackageReference Include="Azure.Messaging.EventHubs.Processor" Version="5.2.0" />
<PackageReference Include="Azure.Messaging.EventHubs" Version="5.3.0" />
<PackageReference Include="Azure.Messaging.EventHubs.Processor" Version="5.3.0" />
<PackageReference Include="Azure.Storage.Blobs" Version="12.8.0" />
<PackageReference Include="Ensure.That" Version="9.2.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Abstractions" Version="2.2.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Core" Version="2.2.5" />
<PackageReference Include="Microsoft.Azure.Management.Storage.Fluent" Version="1.34.0" />
<PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.8">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.Extensions.Hosting" Version="2.2.0" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.8.0">
<PackageReference Include="Microsoft.Azure.Management.Storage.Fluent" Version="1.37.0" />
<PackageReference Include="Microsoft.Extensions.Hosting" Version="3.1.12" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.9.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<ItemGroup>
<PackageReference Include="Ensure.That" Version="9.2.0" />
<PackageReference Include="Hl7.Fhir.R4" Version="2.0.1" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.8.0">
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.9.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand All @@ -28,7 +28,6 @@
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Text.RegularExpressions" Version="4.3.1" />
<PackageReference Include="xunit" Version="2.4.1" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Microsoft.Health.Common\Microsoft.Health.Common.csproj" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="Ensure.That" Version="9.2.0" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.8.0">
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.9.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand All @@ -26,7 +26,6 @@
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Text.RegularExpressions" Version="4.3.1" />
<PackageReference Include="xunit" Version="2.4.1" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Microsoft.Health.Common\Microsoft.Health.Common.csproj" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
<WarningsAsErrors />
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Azure.WebJobs" Version="3.0.23" />
<PackageReference Include="Microsoft.Azure.WebJobs" Version="3.0.25" />
<PackageReference Include="Ensure.That" Version="9.2.0" />
<PackageReference Include="Microsoft.Azure.Services.AppAuthentication" Version="1.3.1" />
<PackageReference Include="Microsoft.IdentityModel.Clients.ActiveDirectory" Version="5.2.4" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.8.0">
<PackageReference Include="Microsoft.Azure.Services.AppAuthentication" Version="1.6.1" />
<PackageReference Include="Microsoft.IdentityModel.Clients.ActiveDirectory" Version="5.2.8" />
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.9.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand All @@ -26,7 +26,6 @@
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Text.RegularExpressions" Version="4.3.1" />
<PackageReference Include="xunit" Version="2.4.1" />
</ItemGroup>
<ItemGroup>
<AdditionalFiles Include="..\..\..\stylecop.json" Link="stylecop.json" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<AdditionalFiles Include="..\..\..\stylecop.json" Link="stylecop.json" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.8.0">
<PackageReference Include="Microsoft.Net.Compilers.Toolset" Version="3.9.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
Expand All @@ -26,6 +26,5 @@
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Text.RegularExpressions" Version="4.3.1" />
<PackageReference Include="xunit" Version="2.4.1" />
</ItemGroup>
</Project>
Loading