-
Notifications
You must be signed in to change notification settings - Fork 570
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
[BUG] Deploy to Azure Button #4929
Comments
@vnetonline I believe you were able to resolve the issues in the Deploy to Azure functionality in the past... are you able to investigate the latest issues? |
Yup I will have a look and investigate and fix |
I have recorded a FREE course on how to setup Oqtane on Local IIS https://learnoqtane.com/course-page/!/4/how-to-setup-oqtane-on-local-iis If you are not a member of LearnOqtane.com .. you can Join Now for FREE |
The Button to deploy to Azure is working properly, however when it has finished getting the source files from the master it fails because of a Build error see below
|
I understand. |
This related to dotnet/sdk#44197 (comment) i have made a comment that this hasn't been resolved |
Can you share your project file? It isn't obvious to me how this behavior is related to that other issue. |
The project file is from git repo Oqtane Framework |
That warning seems pretty important. I just built the code w/o issue. |
FYI for @sbwalker There should be no need for this reference if .NET and STJ version match. You should be able to remove it.
|
@richlander removing the reference to System.Text.Json 9.0 from the Oqtane.Shared project results in a compilation warning in a different project within the solution: 7>C:\Source\Projects\oqtane.framework\Oqtane.Database.MySQL\Oqtane.Database.MySQL.csproj : warning NU1903: Package 'System.Text.Json' 8.0.4 has a known high severity vulnerability, GHSA-8g4q-xg66-9fp4 The Oqtane.Database.MySQL.csproj project is targeted at .NET 9 and references:
These are the latest versions of these packages. I assume that the System.Text.Json is a transitive dependency of one of these 2 packages. I could add a reference to System.Text.Json 9.0 in the Oqtane.Database.MySQL.csproj which would eliminate the compilation warning... however this is essentially the same solution as including the reference to System.Text.Json 9.0 in Oqtane.Shared.csproj. Suggestions? |
@vnetonline do you have any idea why you have this warning message:
The Oqtane solution is being built within the Azure environment during Deploy To Azure, correct? |
That makes sense @sbwalker. You are right. Related: dotnet/sdk#44566 |
@richlander so you are confirming that we should retain the package reference to System.Text.Json 9.0 in Oqtane.Shared.csproj - to ensure that our transitive dependencies do not pull in the vulnerable System.Text.Json 8.0.4 package - correct? |
Yes. Sorry for adding confusion on that. I think the source of the problem is that the wrong SDK is being used. |
BTW: Hi! |
add back System.Text.Json to Shared project (#4929)
@vnetonline the azuredeploy.json file contains a reference to: netFrameworkVersion": "v5.0" Is this correct? |
The file which is in master targets v5.0 but when I am testing I have changed it to v9.0 I can successfully build the project locally. But when Azure is building it by getting the source code from GitHub repo master branch the build on azure results in above error. The error I believe is to do with MSBuild using System.Text.Json 8.0.0.4 I have checked the Oqtane Package it doesn't reference System.Text.Json 8.0.0.4 or any other version of System.Text.Json as a dependency. |
@vnetonline if you read the comments above in this thread you will see that System.Text.Json 8.0.4 is referenced by one of the dependencies in the Oqtane.Database.MySQL project. Perhaps if you add a package reference for System.Text.Json 9.0.0 to the Oqtane.Database.MySQL project it might resolve the build issue in Azure. |
@sbwalker Your latest push in dev branch has resolved the build issue but now I am getting time outs when trying to deploy dev branch I need to figure out a way of increasing the time out .... I am trying to investigate how we can increase time out via deployment script .... we need to add a environment variable SCM_COMMAND_IDEL_TIMEOUT via deployment script which appears to be challenging. |
I have now managed to add the environment variables here is the latest deployment script which still is timing out
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.1",
"parameters": {
"sqlDatabaseEditionTierDtuCapacity": {
"type": "string",
"defaultValue": "Basic-Basic-5-2",
"allowedValues": [
"Basic-Basic-5-2",
"Standard-S0-10-250",
"Standard-S1-20-250",
"Standard-S2-50-250",
"Standard-S3-100-250",
"Standard-S4-200-250",
"Standard-S6-400-250",
"Standard-S7-800-250",
"Standard-S9-1600-250",
"Standard-S12-3000-250",
"Premium-P1-125-500",
"Premium-P2-250-500",
"Premium-P4-500-500" ,
"Premium-P6-1000-500",
"Premium-P11-1750-500-1024",
"Premium-P15-4000-1024",
"GeneralPurpose-GP_Gen5_2-2-250",
"GeneralPurpose-GP_S_Gen5_2-2-250"
],
"metadata": {
"description": "Describes the database Edition, Tier, Dtu, Gigabytes (Edition-Tier-Dtu-Gigabytes)"
}
},
"sqlServerName": {
"type": "string",
"metadata": {
"description": "The name of the sql server. It has to be unique."
}
},
"sqlDatabaseName": {
"type": "string",
"metadata": {
"description": "The name of the sql databaseName. It has to be unique."
}
},
"sqlAdministratorLogin": {
"type": "string",
"metadata": {
"description": "The admin user of the SQL Server"
}
},
"sqlAdministratorLoginPassword": {
"type": "securestring",
"metadata": {
"description": "The password of the admin user of the SQL Server"
}
},
"BlazorWebsiteName": {
"type": "string",
"metadata": {
"description": "The name of the website. It has to be unique."
}
},
"BlazorSKU": {
"type": "string",
"allowedValues": [
"F1",
"D1",
"B1",
"B2",
"B3",
"S1",
"S2",
"S3",
"P1",
"P2",
"P3",
"P4"
],
"defaultValue": "B1"
},
"BlazorSKUCapacity": {
"type": "int",
"defaultValue": 1,
"maxValue": 3,
"minValue": 1,
"metadata": {
"description": "Describes plan's instance count"
}
},
"location": {
"type": "string",
"defaultValue": "[resourceGroup().location]",
"metadata": {
"description": "Location for all resources."
}
}
},
"variables": {
"hostingPlanName": "[concat('Oqtane-hostingplan-', uniqueString(resourceGroup().id))]",
"databaseCollation": "SQL_Latin1_General_CP1_CI_AS",
"databaseEditionTierDtuCapacity": "[split(parameters('sqlDatabaseEditionTierDtuCapacity'),'-')]",
"databaseEdition": "[variables('databaseEditionTierDtuCapacity')[0]]",
"databaseTier": "[variables('databaseEditionTierDtuCapacity')[1]]",
"databaseDtu": "[if(greater(length(variables('databaseEditionTierDtuCapacity')), 2), variables('databaseEditionTierDtuCapacity')[2], '')]",
"databaseMaxSizeGigaBytes":"[if(greater(length(variables('databaseEditionTierDtuCapacity')), 3), variables('databaseEditionTierDtuCapacity')[3], '')]",
"databaseServerlessTiers": [
"GP_S_Gen5_2"
]
},
"resources": [
{
"type": "Microsoft.Sql/servers",
"apiVersion": "2021-11-01",
"name": "[parameters('sqlServerName')]",
"location": "[parameters('location')]",
"tags": {
"displayName": "SQL Server"
},
"properties": {
"administratorLogin": "[parameters('sqlAdministratorLogin')]",
"administratorLoginPassword": "[parameters('sqlAdministratorLoginPassword')]",
"version": "12.0"
}
},
{
"type": "Microsoft.Sql/servers/databases",
"apiVersion": "2021-11-01",
"name": "[format('{0}/{1}', parameters('sqlServerName'), parameters('sqlDatabaseName'))]",
"location": "[parameters('location')]",
"tags": {
"displayName": "Database"
},
"sku": {
"name": "[if(equals(variables('databaseEdition'), 'GeneralPurpose'), variables('databaseTier'), variables('databaseEdition'))]",
"tier": "[variables('databaseEdition')]",
"capacity": "[if(equals(variables('databaseDtu'), ''), json('null'), int(variables('databaseDtu')))]"
},
"kind": "[concat('v12.0,user,vcore',if(contains(variables('databaseServerlessTiers'),variables('databaseTier')),',serverless',''))]",
"properties": {
"edition": "[variables('databaseEdition')]",
"collation": "[variables('databaseCollation')]",
"maxSizeBytes": "[if(equals(variables('databaseMaxSizeGigaBytes'), ''), json('null'), mul(mul(mul(int(variables('databaseMaxSizeGigaBytes')),1024),1024),1024))]",
"requestedServiceObjectiveName": "[variables('databaseTier')]"
},
"dependsOn": [
"[resourceId('Microsoft.Sql/servers', parameters('sqlserverName'))]"
]
},
{
"type": "Microsoft.Sql/servers/firewallRules",
"apiVersion": "2021-11-01",
"name": "[format('{0}/{1}', parameters('sqlServerName'), 'AllowAllWindowsAzureIps')]",
"properties": {
"endIpAddress": "0.0.0.0",
"startIpAddress": "0.0.0.0"
},
"dependsOn": [
"[resourceId('Microsoft.Sql/servers', parameters('sqlServerName'))]"
]
},
{
"name": "[variables('hostingPlanName')]",
"type": "Microsoft.Web/serverfarms",
"location": "[resourceGroup().location]",
"apiVersion": "2024-04-01",
"dependsOn": [],
"tags": {
"displayName": "Blazor"
},
"sku": {
"name": "[parameters('BlazorSKU')]",
"capacity": "[parameters('BlazorSKUCapacity')]"
},
"properties": {
"name": "[variables('hostingPlanName')]",
"numberOfWorkers": 1
}
},
{
"apiVersion": "2024-04-01",
"name": "[parameters('BlazorWebsiteName')]",
"type": "Microsoft.Web/sites",
"location": "[parameters('location')]",
"dependsOn": [
"[variables('hostingPlanName')]"
],
"tags": {
"[concat('hidden-related:', resourceId('Microsoft.Web/serverfarms', variables('hostingPlanName')))]": "empty",
"displayName": "Website"
},
"properties": {
"name": "[parameters('BlazorWebsiteName')]",
"serverFarmId": "[resourceId('Microsoft.Web/serverfarms', variables('hostingPlanName'))]",
"siteConfig": {
"webSocketsEnabled": true,
"use32BitWorkerProcess": false,
"netFrameworkVersion": "v9.0",
"metadata": [
{
"name": "CURRENT_STACK",
"value": "dotnet"
}
]
}
},
"resources": [
{
"type": "sourcecontrols",
"apiVersion": "2024-04-01",
"name": "web",
"location": "[parameters('location')]",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', parameters('BlazorWebsiteName'))]"
//"[resourceId('Microsoft.Web/Sites/config', parameters('BlazorWebsiteName'), 'connectionstrings')]"
],
"properties": {
"RepoUrl": "https://github.com/oqtane/oqtane.framework.git",
"branch": "dev",
"IsManualIntegration": true
}
},
{
"name": "appsettings",
"type": "config",
"apiVersion": "2015-08-01",
"dependsOn": [
"[resourceId('Microsoft.Web/sites', parameters('BlazorWebsiteName'))]"
],
"tags": {
"displayName": "appsettings"
},
"properties": {
"SCM_COMMAND_IDLE_TIMEOUT": "3600",
"WEBJOBS_IDLE_TIMEOUT": "3600"
}
}
]
}
]
} |
You guys are great btw. Thanks for your support and happy Holidays to all of you :) |
So is there hope that this nice little button will work again soon? :) |
@ubidev - Can you test the Deploy To Azure button on this project: https://github.com/ADefWebserver/Blazor-Blogs |
Oqtane Info
Version - 6.0.0
Render Mode - Static
Interactivity - Server
Database - SQL Server
Describe the bug
I just successfully ran the "deploy to azure" button BUT when I go to the https://websitename.azurewebsites.net URL I get a default azure website status page instead of the oqtane initialization wizard
Expected Behavior
once deployed I should get the oqtane initialize wizard
Steps To Reproduce
click the "deploy to azure" button
fill the form with acceptable values
create
wait for success
clic the website provided address
Anything else?
I know there is a manuall way to do this documented here: https://blazorhelpwebsite.com/ViewBlogPost/1 but I really need that wizard to work because I plan to demonstrate/use oqtane during classes to noobs
Thanks in advance for taking the time. This project is simply Amazing
The text was updated successfully, but these errors were encountered: