BryanWilhite / Songhay.Feeds

Collects Syndication feeds in JSON format for UI presentation.
MIT License
0 stars 0 forks source link

change studio Feed #16

Open BryanWilhite opened 4 years ago

BryanWilhite commented 4 years ago

"studio": "https://songhaystorage.blob.core.windows.net/day-path-blog/site-rss.xml"

needs to change to

"studio": "http://songhayblog.azurewebsites.net/entry/feed.xml"

BryanWilhite commented 4 years ago

the release in AzDO is broken ☹️

the shell context of the release cannot 'see' Azure Web Sites anymore such that a script like this

$job =
@{
    Name = "job-feeds";
    SubscriptionName = "My Subscription";
    WebSiteName = "my-web-site-name";
    ZipFile = "$env:AGENT_RELEASEDIRECTORY\$env:BUILD_DEFINITIONNAME\drop\MyWebJobRelease.zip";
}

Get-AzureSubscription -SubscriptionName $job.SubscriptionName
Select-AzureSubscription -SubscriptionName $job.SubscriptionName

Get-AzureWebsite | ForEach-Object {Get-AzureWebsite -Name $_.Name}

New-AzureWebsiteJob `
    -Name $job.WebSiteName `
    -JobName $job.Name `
    -JobType Triggered `
    -JobFile $job.ZipFile

returns ##[error]The website my-web-site-name was not found. Please specify a valid website name.

BryanWilhite commented 4 years ago

specifically, this command, Get-AzureWebsite | ForEach-Object {Get-AzureWebsite -Name $_.Name} , returns nothing

this could be due to the type of connection the AzDO Task is using, a 'classic' connection or a Azure Resource Manager (RM) connection

the original script used a 'classic' connection: image

switching to Azure RM means learning RM PowerShell module equivalents 🐰 🕳

BryanWilhite commented 4 years ago

switching to the Azure CLI made me open this issue: https://github.com/Azure/azure-cli/issues/11636 (which i assume will not be resolved to my satisfaction today)

BryanWilhite commented 4 years ago

i strongly suspect that the original script no longer works for security reasons and/or the 'classic' Azure PowerShell module is no longer supported---or the automatic deployment of WebJobs is no longer supported (to encourage the use of Azure Durable Functions)

this article from 2017 shows me how complicated it is to use Azure RM: https://github.com/projectkudu/kudu/wiki/Deploying-a-WebJob-using-PowerShell-ARM-Cmdlets

BryanWilhite commented 4 years ago

i've manually edited my way out of this: image

BryanWilhite commented 4 years ago

Using the latest Az Module, I find that there is no equivalent for New-AzureWebsiteJob; New-AzureWebsiteJob has an -AsJob parameter that has nothing to do with a WebJob

https://docs.microsoft.com/en-us/powershell/module/az.websites/new-azwebapp?view=azps-3.2.0