Replies: 1 comment
|
Yes, this is achievable — Bicep has supported a What changes in your templateSince this is a Standard (single-tenant) Logic App, the trigger isn't a separate top-level ARM resource the way it is in Consumption — the callback URL has to be resolved via the @description('Name of the workflow inside the Logic App (Standard) that contains the HTTP trigger')
param workflowName string
@description('Name of the trigger inside the workflow, e.g. "When_a_HTTP_request_is_received"')
param triggerName string = 'manual'
// ...your existing `site` resource stays exactly as-is...
@secure()
output workflowCallbackUrl string = listCallbackUrl(
'${site.id}/hostruntime/runtime/webhooks/workflow/api/management/workflows/${workflowName}/triggers/${triggerName}',
'2018-11-01'
).valueA couple of notes on the syntax:
The important caveat
That means with So to make this output reliably resolve, you still need one of:
Bottom line: |
Uh oh!
There was an error while loading. Please reload this page.
We need to enable the Logic App (LA) module to return a callback URL as a secure output, so it can be safely consumed by downstream modules or callers, and this should be achievable using the Bicep template below.
Below logic app bicep template
@description('App service containing the workflow runtime')
resource site 'Microsoft.Web/sites@2024-11-01' = {
name: <LOGIC_APP_NAME>
location: location
kind: 'functionapp,workflowapp'
identity: {
type: 'SystemAssigned'
}
properties: {
virtualNetworkSubnetId:
hostNameSslStates: [
{
name: '${<LOGIC_APP_NAME>}.azurewebsites.net'
sslState: 'Disabled'
hostType: 'Standard'
}
{
name: '${<LOGIC_APP_NAME>}.scm.azurewebsites.net'
sslState: 'Disabled'
hostType: 'Repository'
}
]
siteConfig: {
appSettings: concat([
{
name: 'FUNCTIONS_EXTENSION_VERSION'
value: '~4'
}
{
name: 'FUNCTIONS_WORKER_RUNTIME'
value: 'node'
}
{
name: 'WEBSITE_NODE_DEFAULT_VERSION'
value: '~20'
}
{
name: 'AzureWebJobsStorage'
value: 'DefaultEndpointsProtocol=https;AccountName=${<STORAGE_ACCOUNT_NAME>};...'
}
{
name: 'WEBSITE_CONTENTAZUREFILECONNECTIONSTRING'
value: 'DefaultEndpointsProtocol=https;AccountName=${<STORAGE_ACCOUNT_NAME>};...'
}
{
name: 'WEBSITE_CONTENTSHARE'
value: '${<STORAGE_ACCOUNT_NAME>}-content'
}
{
name: 'AzureFunctionsJobHost__extensionBundle__id'
value: 'Microsoft.Azure.Functions.ExtensionBundle.Workflows'
}
{
name: 'AzureFunctionsJobHost__extensionBundle__version'
value: '[1.*, 2.0.0)'
}
{
name: 'APP_KIND'
value: 'workflowApp'
}
{
name: 'WORKFLOWS_TENANT_ID'
value: subscription().tenantId
}
{
name: 'WORKFLOWS_SUBSCRIPTION_ID'
value: subscription().subscriptionId
}
{
name: 'WORKFLOWS_RESOURCE_GROUP_NAME'
value: resourceGroup().name
}
{
name: 'WORKFLOWS_LOCATION_NAME'
value: location
}
{
name: 'Environment'
value: environment
}
{
name: 'AzureWebJobsFeatureFlags'
value: 'EnableMultiLanguageWorker'
}
]
use32BitWorkerProcess: true
cors: {
allowedOrigins: [
'https://portal.azure.com'
]
}
minTlsVersion: '1.2'
ftpsState: 'FtpsOnly'
nodeVersion: '~20'
}
serverFarmId: <APPSERVICE_PLAN_ID>
publicNetworkAccess: 'Disabled'
outboundVnetRouting: {
allTraffic: false
applicationTraffic: true
contentShareTraffic: true
imagePullTraffic: false
backupRestoreTraffic: false
}
scmSiteAlsoStopped: false
clientAffinityEnabled: false
clientCertEnabled: false
clientCertMode: 'Required'
hostNamesDisabled: false
customDomainVerificationId: '<CUSTOM_DOMAIN_VERIFICATION_ID>'
containerSize: 1536
dailyMemoryTimeQuota: 0
httpsOnly: true
redundancyMode: 'None'
storageAccountRequired: false
keyVaultReferenceIdentity: 'SystemAssigned'
}
tags: tags
}
All reactions