AzureContainerAppsDeployer
Class: AzureContainerAppsDeployer
Defined in: azure/src/deployers/containerapps.service.ts:67
Build an OCI image and deploy its immutable digest to Azure Container Apps.
Webda Modda
Extends
Implements
Deployer
Constructors
Constructor
new AzureContainerAppsDeployer(
name,params):AzureContainerAppsDeployer
Defined in: core/lib/services/service.d.ts:72
Create a new Service instance
Service
Parameters
name
string
The name of the service
params
AzureContainerAppsDeployerParameters
The parameters block define in the configuration file
Returns
AzureContainerAppsDeployer
Inherited from
Properties
_compiledCapabilities
protected_compiledCapabilities:Record<string,any>
Defined in: core/lib/services/iservice.d.ts:50
Capabilities detected at compile-time from @WebdaCapability-tagged interfaces.
Populated during Service.resolve by reading the service's entry in
webda.module.json. Each key is a capability name (e.g., "request-filter"),
and the value is an empty object {} by default. Override getCapabilities
to provide capability-specific configuration or to conditionally disable capabilities.
See
getCapabilities
Inherited from
AzureArmDeployer._compiledCapabilities
[WEBDA_EVENTS]
[WEBDA_EVENTS]:
object
Defined in: core/lib/services/service.d.ts:50
Set the Webda events here
Inherited from
AzureArmDeployer.[WEBDA_EVENTS]
contributedEnv
protectedcontributedEnv:Record<string,string| {secretRef:string; }> ={}
Defined in: azure/src/deployers/arm.service.ts:137
Contributed env
Inherited from
AzureArmDeployer.contributedEnv
image
protectedimage:string=""
Defined in: azure/src/deployers/containerapps.service.ts:78
Image
logger
protectedlogger:Logger
Defined in: core/lib/services/service.d.ts:59
Logger with class context
Inherited from
metrics?
protectedoptionalmetrics?:object
Defined in: core/lib/services/service.d.ts:63
Get metrics
Inherited from
name
readonlyname:string
Defined in: core/lib/services/iservice.d.ts:27
Name
Inherited from
parameters
readonlyparameters:AzureContainerAppsDeployerParameters
Defined in: core/lib/services/iservice.d.ts:31
Parameters
Inherited from
resources
resources:
AzureContainerAppsDeployerParameters
Defined in: azure/src/deployers/arm.service.ts:121
Resources
Inherited from
result?
optionalresult?:AzureDeployResult
Defined in: azure/src/deployers/arm.service.ts:129
Result
Inherited from
roles
protectedroles:AzureRoleAssignment[] =[]
Defined in: azure/src/deployers/arm.service.ts:141
Roles
Inherited from
secretValues
protectedsecretValues:Map<string,string|SecretString>
Defined in: azure/src/deployers/arm.service.ts:133
Secret values
Inherited from
template
template:
AzureTemplate
Defined in: azure/src/deployers/arm.service.ts:125
Template
Inherited from
createConfiguration?
staticoptionalcreateConfiguration?: (params) =>any
Defined in: core/lib/services/iservice.d.ts:35
Create configuration set by the application on load
Parameters
params
any
Returns
any
Inherited from
AzureArmDeployer.createConfiguration
filterConfiguration?
staticoptionalfilterConfiguration?: (params) =>any
Defined in: core/lib/services/iservice.d.ts:39
Create configuration set by the application on load
Parameters
params
any
Returns
any
Inherited from
AzureArmDeployer.filterConfiguration
Parameters
staticParameters: typeofAzureContainerAppsDeployerParameters=AzureContainerAppsDeployerParameters
Defined in: azure/src/deployers/containerapps.service.ts:74
Parameters
Overrides
Methods
__clean()
abstract__clean():Promise<void>
Defined in: core/lib/services/service.d.ts:224
Clean the service data, can only be used in test mode
Returns
Promise<void>
Inherited from
addListener()
addListener<
Key>(eventName,listener):this
Defined in: core/lib/events/asynceventemitter.d.ts:87
Add listener
Type Parameters
Key
Key extends never
Parameters
eventName
Key
the event name
listener
(event) => void | Promise<void>
the event listener
Returns
this
this for chaining
See
EventEmitter.addListener
Inherited from
addResource()
protectedaddResource(resource):void
Defined in: azure/src/deployers/arm.service.ts:229
Add a resource, rejecting conflicting declarations.
Parameters
resource
Record<string, any>
ARM resource declaration
Returns
void
Inherited from
addRoute()
protectedaddRoute(url,methods,executer,openapi?,override?):void
Defined in: core/lib/services/service.d.ts:177
Add a route dynamicaly
Parameters
url
string
of the route can contains dynamic part like {uuid}
methods
HttpMethodType[]
the HTTP methods
executer
Function
Method to execute for this route
openapi?
OpenAPIWebdaDefinition
the OpenAPI specification
override?
boolean
whether to override existing
Returns
void
Inherited from
authorizeClientEvent()
authorizeClientEvent(
_event,_context):boolean
Defined in: core/lib/services/service.d.ts:153
Authorize a public event subscription
Parameters
_event
string
the event name
_context
OperationContext
the execution context
Returns
boolean
true if the condition is met
Inherited from
AzureArmDeployer.authorizeClientEvent
build()
build(
output?):Promise<string>
Defined in: oci/lib/container.service.d.ts:173
Build the image into an OCI layout folder or tar archive
Load the archive with podman load -i <file> or copy it with skopeo copy oci-archive:<file> ....
Parameters
output?
string
Output folder, or tar archive when ending with .tar
Returns
Promise<string>
the output path
Inherited from
buildImage()
buildImage(
parameters,output,includeBaseLayers):Promise<BuiltImage>
Defined in: oci/lib/container.service.d.ts:157
Build the image into an OCI layout
Parameters
parameters
ContainerDeployerParameters
the resolved parameters
output
string
the layout folder
includeBaseLayers
boolean
download the base layers into the layout
Returns
Promise<BuiltImage>
the built image
Inherited from
computeParameters()
computeParameters():
void
Defined in: core/lib/services/service.d.ts:77
Used to compute or derivate input parameter to attribute
Returns
void
Deprecated
Inherited from
AzureArmDeployer.computeParameters
ContainerApp()
ContainerApp():
void
Defined in: azure/src/deployers/containerapps.service.ts:281
Add the application and its scaling and ingress settings.
Returns
void
deploy()
deploy():
Promise<AzureDeployResult>
Defined in: azure/src/deployers/containerapps.service.ts:456
Publish and deploy the application, returning its endpoints.
Returns
Promise<AzureDeployResult>
The deploy result
Overrides
emit()
emit<
Key>(event,data):Promise<void>
Defined in: core/lib/services/service.d.ts:213
Emit the event with data and wait for Promise to finish if listener returned a Promise
Type Parameters
Key
Key extends never
Parameters
event
Key
the event name
data
object[Key]
the data to process
Returns
Promise<void>
Inherited from
env()
protectedenv():object[]
Defined in: azure/src/deployers/containerapps.service.ts:160
Build the runtime environment from contributors and explicit overrides.
Returns
object[]
The env result
environmentId()
protectedenvironmentId():string
Defined in: azure/src/deployers/containerapps.service.ts:144
Return the managed environment resource identifier.
Returns
string
The environment id result
generate()
generate(
output?):Promise<AzureTemplate>
Defined in: azure/src/deployers/containerapps.service.ts:86
Write the generated ARM template for review.
Parameters
output?
string
Optional template output path
Returns
Promise<AzureTemplate>
Generated ARM template
Overrides
generateTemplate()
generateTemplate(
image?):AzureTemplate
Defined in: azure/src/deployers/containerapps.service.ts:194
Generate the deployment template without contacting Azure.
Parameters
image?
string
Immutable container image reference
Returns
ARM template without secret values
Overrides
AzureArmDeployer.generateTemplate
getAppPrincipalId()
getAppPrincipalId():
string
Defined in: azure/src/deployers/containerapps.service.ts:137
Return the ARM expression for the application principal.
Returns
string
The app principal id result
Overrides
AzureArmDeployer.getAppPrincipalId
getAppResourceId()
getAppResourceId():
string
Defined in: azure/src/deployers/containerapps.service.ts:120
Return the application resource identifier.
Returns
string
The app resource id result
Overrides
AzureArmDeployer.getAppResourceId
getCapabilities()
getCapabilities():
Record<string,any>
Defined in: core/lib/services/iservice.d.ts:72
Return the capabilities of this service.
By default returns capabilities detected at compile-time from
Returns
Record<string, any>
the result
Webda Capability-tagged
interfaces in webda.module.json.
Override to disable capabilities based on configuration:
getCapabilities() {
const caps = super.getCapabilities();
if (!this.parameters.enabled) delete caps["request-filter"];
return caps;
}
Inherited from
AzureArmDeployer.getCapabilities
getClientEvents()
getClientEvents():
string[]
Defined in: core/lib/services/service.d.ts:144
Return the events that an external system can subscribe to
Returns
string[]
the list of results
Inherited from
AzureArmDeployer.getClientEvents
getDefaultTags()
getDefaultTags(
tags?):Record<string,string>
Defined in: azure/src/deployers/arm.service.ts:171
Merge deployment tags with resource tags.
Parameters
tags?
Record<string, string> = {}
Resource-specific tags
Returns
Record<string, string>
The default tags result
Inherited from
AzureArmDeployer.getDefaultTags
getIdentityResourceId()
protectedgetIdentityResourceId():string
Defined in: azure/src/deployers/containerapps.service.ts:127
Return the managed identity resource identifier.
Returns
string
The identity resource id result
Overrides
AzureArmDeployer.getIdentityResourceId
getLayerEntries()
getLayerEntries(
parameters):Promise<TarEntry[]>
Defined in: oci/lib/container.service.d.ts:148
Files of the application layer: the packaged application under the working directory
Parameters
parameters
ContainerDeployerParameters
the resolved parameters
Returns
Promise<TarEntry[]>
the layer entries
Inherited from
AzureArmDeployer.getLayerEntries
getMaxListeners()
getMaxListeners():
number
Defined in: core/lib/events/asynceventemitter.d.ts:91
Returns
number
Inherited from
AzureArmDeployer.getMaxListeners
getMetric()
getMetric<
T>(type,configuration):T
Defined in: core/lib/services/service.d.ts:138
Add service name label
Type Parameters
T
T = Gauge<string> | Counter<string> | Histogram<string>
Parameters
type
CustomConstructor<T, [MetricConfiguration<T>]>
the type to look up
configuration
MetricConfiguration<T>
the configuration
Returns
T
the result
Inherited from
getName()
getName():
string
Defined in: core/lib/services/service.d.ts:218
Get service name
Returns
string
the result string
Inherited from
getOpenApiReplacements()
getOpenApiReplacements():
any
Defined in: core/lib/services/service.d.ts:182
Return variables for replacement in openapi
Returns
any
the result
Inherited from
AzureArmDeployer.getOpenApiReplacements
getOperationId()
getOperationId(
id):string|undefined
Defined in: core/lib/services/service.d.ts:167
If undefined is returned it cancel the operation registration
Parameters
id
string
the identifier
Returns
string | undefined
the result
Inherited from
AzureArmDeployer.getOperationId
getParameters()
getParameters():
AzureContainerAppsDeployerParameters
Defined in: core/lib/services/service.d.ts:82
Get the service parameters
Returns
AzureContainerAppsDeployerParameters
the result
Inherited from
AzureArmDeployer.getParameters
getResolvedParameters()
getResolvedParameters():
AzureContainerAppsDeployerParameters
Defined in: azure/src/deployers/containerapps.service.ts:94
Perform get resolved parameters.
Returns
AzureContainerAppsDeployerParameters
Overrides
AzureArmDeployer.getResolvedParameters
getService()
getService<
T>(name):ServicesMap[T]
Defined in: core/lib/services/service.d.ts:131
Get a service by name
Type Parameters
T
T extends keyof ServicesMap
Parameters
name
T
the name to use
Returns
ServicesMap[T]
the result map
Deprecated
Use useService, might reconsider
Inherited from
getState()
getState():
ServiceStates
Defined in: core/lib/services/service.d.ts:55
Get the current state
Returns
ServiceStates
the result
Inherited from
getUrl()
getUrl(
url,_methods):string
Defined in: core/lib/services/service.d.ts:161
Return the full path url based on parameters
Parameters
url
string
relative url to service
_methods
HttpMethodType[]
in case we need filtering (like Store)
Returns
string
absolute url or undefined if need to skip the Route
Inherited from
grantRoles()
protectedgrantRoles(principalId?,identityResourceId?):void
Defined in: azure/src/deployers/arm.service.ts:247
Grant every contributed role to one application or job identity.
Parameters
principalId?
string = ...
ARM principal identifier expression
identityResourceId?
string = ...
Resource providing the managed identity
Returns
void
Inherited from
identity()
protectedidentity():object
Defined in: azure/src/deployers/containerapps.service.ts:153
Describe the application managed identity.
Returns
object
The identity result
type
type:
string="SystemAssigned, UserAssigned"
userAssignedIdentities
userAssignedIdentities:
object
Index Signature
[key: string]: object
init()
abstractinit():Promise<AzureContainerAppsDeployer>
Defined in: core/lib/services/service.d.ts:207
Will be called after all the Services are created
Returns
Promise<AzureContainerAppsDeployer>
Inherited from
initMetrics()
initMetrics():
void
Defined in: core/lib/services/service.d.ts:124
Init the metrics
Returns
void
Inherited from
initOperations()
initOperations():
void
Defined in: core/lib/services/service.d.ts:195
Init the operations from
Returns
void
Operation
decorators on this service
Inherited from
AzureArmDeployer.initOperations
Jobs()
Jobs():
void
Defined in: azure/src/deployers/containerapps.service.ts:392
Export declared crons as scheduled jobs, each running cron run --id on its operation.
Returns
void
listeners()
listeners(
eventName):Function[]
Defined in: core/lib/events/asynceventemitter.d.ts:151
Get all listeners for an event
Parameters
eventName
never
the event name
Returns
Function[]
the list of results
Inherited from
loadCapabilities()
protectedloadCapabilities():void
Defined in: core/lib/services/service.d.ts:120
Load capabilities from webda.module.json metadata into _compiledCapabilities.
Called during resolve after dependency injection. Reads the service's
type name from parameters, looks it up in the application's module metadata
(moddas or beans section), and populates _compiledCapabilities with an
empty object for each declared capability name.
Fails silently if the application is not available (e.g., in unit tests where services are instantiated without a full application context).
Returns
void
Example
// If webda.module.json contains:
// { "moddas": { "MyApp/HawkService": { "capabilities": ["request-filter", "cors-filter"] } } }
// Then after resolve(), this.getCapabilities() returns:
// { "request-filter": {}, "cors-filter": {} }
See
getCapabilities
Inherited from
AzureArmDeployer.loadCapabilities
log()
log(
level, ...args):void
Defined in: core/lib/services/service.d.ts:236
Log operation
Parameters
level
WorkerLogLevel
to log
args
...any[]
additional arguments
Returns
void
Inherited from
LogAnalytics()
LogAnalytics():
void
Defined in: azure/src/deployers/containerapps.service.ts:235
Add the optional Log Analytics workspace.
Returns
void
ManagedCertificates()
ManagedCertificates():
void
Defined in: azure/src/deployers/containerapps.service.ts:339
Issue managed certificates after hostname registration, then bind them in a nested deployment.
Returns
void
ManagedEnvironment()
ManagedEnvironment():
void
Defined in: azure/src/deployers/containerapps.service.ts:251
Add the Container Apps managed environment.
Returns
void
off()
off<
Key>(eventName,listener):this
Defined in: core/lib/events/asynceventemitter.d.ts:127
Perform off
Type Parameters
Key
Key extends never
Parameters
eventName
Key
the event name
listener
(event) => void
the event listener
Returns
this
this for chaining
See
EventEmitter.off
Inherited from
on()
on<
Key>(eventName,listener):this
Defined in: core/lib/events/asynceventemitter.d.ts:111
Perform on
Type Parameters
Key
Key extends never
Parameters
eventName
Key
the event name
listener
(event) => void
the event listener
Returns
this
this for chaining
See
EventEmitter.once
Inherited from
once()
once<
Key>(eventName,listener):this
Defined in: core/lib/events/asynceventemitter.d.ts:103
Perform once
Type Parameters
Key
Key extends never
Parameters
eventName
Key
the event name
listener
(event) => void
the event listener
Returns
this
this for chaining
See
EventEmitter.once
Inherited from
operationSchemaName()
protectedoperationSchemaName(method,side):string
Defined in: core/lib/services/service.d.ts:191
Schema of an operation side: <service name>.<method>.<side> when the application knows it, else the one the
build writes, <class>.<method>.<side>, for the class or its nearest ancestor that has it (a service configured
under another name than its class)
Parameters
method
string
the method name
side
"input" | "output"
input or output
Returns
string
the schema name
Inherited from
AzureArmDeployer.operationSchemaName
prepare()
protectedprepare():void
Defined in: azure/src/deployers/arm.service.ts:154
Resolve the deployment scope and reset template state.
Returns
void
Inherited from
push()
push():
Promise<string>
Defined in: azure/src/deployers/containerapps.service.ts:441
Publish the OCI image using the selected registry authentication.
Returns
Promise<string>
The push result
Overrides
registries()
protectedregistries():object[]
Defined in: azure/src/deployers/containerapps.service.ts:183
Configure managed identity image pulls.
Returns
object[]
The registries result
removeAllListeners()
removeAllListeners<
Key>(eventName?):this
Defined in: core/lib/events/asynceventemitter.d.ts:134
Remove all listeners
Type Parameters
Key
Key extends never
Parameters
eventName?
Key
the event name
Returns
this
this for chaining
See
EventEmitter.removeAllListeners
Inherited from
AzureArmDeployer.removeAllListeners
removeListener()
removeListener<
Key>(eventName,listener):this
Defined in: core/lib/events/asynceventemitter.d.ts:119
Remove listener
Type Parameters
Key
Key extends never
Parameters
eventName
Key
the event name
listener
(event) => void
the event listener
Returns
this
this for chaining
See
EventEmitter.removeListener
Inherited from
AzureArmDeployer.removeListener
resolve()
resolve():
this
Defined in: core/lib/services/service.d.ts:98
Resolve parameters and load metadata. @Route-declared routes are scanned
and registered by Router.discoverRoutes(services) from Core.init()
once every service has resolved — nothing to do per-service here.
Returns
this
the result
Inherited from
resolveOutput()
protectedresolveOutput(output):string
Defined in: oci/lib/container.service.d.ts:164
Resolve the output path against the application folder
Parameters
output
string
the output from the parameters or the command line
Returns
string
the absolute path
Inherited from
AzureArmDeployer.resolveOutput
Resources()
Resources():
void
Defined in: azure/src/deployers/arm.service.ts:204
Merge service resources, environment and roles. Conflicting contributions are rejected.
Returns
void
Inherited from
secrets()
protectedsecrets(): ({identity:string;keyVaultUrl:string;name:string; } | {name:string;value:string; })[]
Defined in: azure/src/deployers/containerapps.service.ts:171
Convert configured secrets to secure parameters or Key Vault references.
Returns
({ identity: string; keyVaultUrl: string; name: string; } | { name: string; value: string; })[]
The secrets result
secureParameter()
protectedsecureParameter(value):string
Defined in: azure/src/deployers/arm.service.ts:194
Add a secret without placing its value in the serializable template.
Parameters
value
string | SecretString
Value to convert or protect
Returns
string
The secure parameter result
Inherited from
AzureArmDeployer.secureParameter
sendTemplate()
sendTemplate():
Promise<Record<string,any>>
Defined in: azure/src/deployers/arm.service.ts:302
Deploy the ARM template with secure parameter values.
Returns
Promise<Record<string, any>>
Deployment outputs
Inherited from
setMaxListeners()
setMaxListeners(
n):this
Defined in: core/lib/events/asynceventemitter.d.ts:95
Parameters
n
number
Returns
this
Inherited from
AzureArmDeployer.setMaxListeners
stop()
stop():
Promise<void>
Defined in: core/lib/services/service.d.ts:86
Shutdown the current service if action need to be taken
Returns
Promise<void>
Inherited from
toJSON()
toJSON():
string
Defined in: core/lib/services/service.d.ts:200
Prevent service to be serialized
Returns
string
the result
Inherited from
toString()
toString():
string
Defined in: core/lib/services/service.d.ts:91
Return service representation
Returns
string
the result
Inherited from
writeTemplate()
protectedwriteTemplate(output?):void
Defined in: azure/src/deployers/arm.service.ts:289
Save the current template with secure parameters left as references.
Parameters
output?
string
Optional template output path
Returns
void