import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Manages a Container App Job. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as azure from "@pulumi/azure"; * * const example = new azure.core.ResourceGroup("example", { * name: "example-resources", * location: "West Europe", * }); * const exampleAnalyticsWorkspace = new azure.operationalinsights.AnalyticsWorkspace("example", { * name: "example-log-analytics-workspace", * location: example.location, * resourceGroupName: example.name, * sku: "PerGB2018", * retentionInDays: 30, * }); * const exampleEnvironment = new azure.containerapp.Environment("example", { * name: "example-container-app-environment", * location: example.location, * resourceGroupName: example.name, * logAnalyticsWorkspaceId: exampleAnalyticsWorkspace.id, * }); * const exampleJob = new azure.containerapp.Job("example", { * name: "example-container-app-job", * location: example.location, * resourceGroupName: example.name, * containerAppEnvironmentId: exampleEnvironment.id, * replicaTimeoutInSeconds: 10, * replicaRetryLimit: 10, * manualTriggerConfig: { * parallelism: 4, * replicaCompletionCount: 1, * }, * template: { * containers: [{ * image: "repo/testcontainerAppsJob0:v1", * name: "testcontainerappsjob0", * readinessProbes: [{ * transport: "HTTP", * port: 5000, * }], * livenessProbes: [{ * transport: "HTTP", * port: 5000, * path: "/health", * headers: [{ * name: "Cache-Control", * value: "no-cache", * }], * initialDelay: 5, * intervalSeconds: 20, * timeout: 2, * failureCountThreshold: 1, * }], * startupProbes: [{ * transport: "TCP", * port: 5000, * }], * cpu: 0.5, * memory: "1Gi", * }], * }, * }); * ``` * * ## API Providers * * * This resource uses the following Azure API Providers: * * * `Microsoft.App` - 2025-07-01 * * ## Import * * A Container App Job can be imported using the resource id, e.g. * * ```sh * $ pulumi import azure:containerapp/job:Job example "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/example-resources/providers/Microsoft.App/jobs/example-container-app-job" * ``` */ export declare class Job extends pulumi.CustomResource { /** * Get an existing Job resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: JobState, opts?: pulumi.CustomResourceOptions): Job; /** * Returns true if the given object is an instance of Job. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is Job; /** * The ID of the Container App Environment in which to create the Container App Job. Changing this forces a new resource to be created. */ readonly containerAppEnvironmentId: pulumi.Output; /** * The endpoint for the Container App Job event stream. */ readonly eventStreamEndpoint: pulumi.Output; /** * A `eventTriggerConfig` block as defined below. Changing this forces a new resource to be created. */ readonly eventTriggerConfig: pulumi.Output; /** * A `identity` block as defined below. */ readonly identity: pulumi.Output; /** * Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created. */ readonly location: pulumi.Output; /** * A `manualTriggerConfig` block as defined below. Changing this forces a new resource to be created. */ readonly manualTriggerConfig: pulumi.Output; /** * Specifies the name of the Container App Job resource. Changing this forces a new resource to be created. */ readonly name: pulumi.Output; /** * A list of the Public IP Addresses which the Container App uses for outbound network access. */ readonly outboundIpAddresses: pulumi.Output; /** * One or more `registry` blocks as defined below. */ readonly registries: pulumi.Output; /** * The maximum number of times a replica is allowed to retry. */ readonly replicaRetryLimit: pulumi.Output; /** * The maximum number of seconds a replica is allowed to run. */ readonly replicaTimeoutInSeconds: pulumi.Output; /** * The name of the resource group in which to create the Container App Job. Changing this forces a new resource to be created. */ readonly resourceGroupName: pulumi.Output; /** * A `scheduleTriggerConfig` block as defined below. Changing this forces a new resource to be created. * * > **Note:** Only one of `manualTriggerConfig`, `eventTriggerConfig` or `scheduleTriggerConfig` can be specified. */ readonly scheduleTriggerConfig: pulumi.Output; /** * One or more `secret` blocks as defined below. */ readonly secrets: pulumi.Output; /** * A mapping of tags to assign to the resource. */ readonly tags: pulumi.Output<{ [key: string]: string; } | undefined>; /** * A `template` block as defined below. */ readonly template: pulumi.Output; /** * The name of the workload profile to use for the Container App Job. */ readonly workloadProfileName: pulumi.Output; /** * Create a Job resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: JobArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering Job resources. */ export interface JobState { /** * The ID of the Container App Environment in which to create the Container App Job. Changing this forces a new resource to be created. */ containerAppEnvironmentId?: pulumi.Input; /** * The endpoint for the Container App Job event stream. */ eventStreamEndpoint?: pulumi.Input; /** * A `eventTriggerConfig` block as defined below. Changing this forces a new resource to be created. */ eventTriggerConfig?: pulumi.Input; /** * A `identity` block as defined below. */ identity?: pulumi.Input; /** * Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created. */ location?: pulumi.Input; /** * A `manualTriggerConfig` block as defined below. Changing this forces a new resource to be created. */ manualTriggerConfig?: pulumi.Input; /** * Specifies the name of the Container App Job resource. Changing this forces a new resource to be created. */ name?: pulumi.Input; /** * A list of the Public IP Addresses which the Container App uses for outbound network access. */ outboundIpAddresses?: pulumi.Input[]>; /** * One or more `registry` blocks as defined below. */ registries?: pulumi.Input[]>; /** * The maximum number of times a replica is allowed to retry. */ replicaRetryLimit?: pulumi.Input; /** * The maximum number of seconds a replica is allowed to run. */ replicaTimeoutInSeconds?: pulumi.Input; /** * The name of the resource group in which to create the Container App Job. Changing this forces a new resource to be created. */ resourceGroupName?: pulumi.Input; /** * A `scheduleTriggerConfig` block as defined below. Changing this forces a new resource to be created. * * > **Note:** Only one of `manualTriggerConfig`, `eventTriggerConfig` or `scheduleTriggerConfig` can be specified. */ scheduleTriggerConfig?: pulumi.Input; /** * One or more `secret` blocks as defined below. */ secrets?: pulumi.Input[]>; /** * A mapping of tags to assign to the resource. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * A `template` block as defined below. */ template?: pulumi.Input; /** * The name of the workload profile to use for the Container App Job. */ workloadProfileName?: pulumi.Input; } /** * The set of arguments for constructing a Job resource. */ export interface JobArgs { /** * The ID of the Container App Environment in which to create the Container App Job. Changing this forces a new resource to be created. */ containerAppEnvironmentId: pulumi.Input; /** * A `eventTriggerConfig` block as defined below. Changing this forces a new resource to be created. */ eventTriggerConfig?: pulumi.Input; /** * A `identity` block as defined below. */ identity?: pulumi.Input; /** * Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created. */ location?: pulumi.Input; /** * A `manualTriggerConfig` block as defined below. Changing this forces a new resource to be created. */ manualTriggerConfig?: pulumi.Input; /** * Specifies the name of the Container App Job resource. Changing this forces a new resource to be created. */ name?: pulumi.Input; /** * One or more `registry` blocks as defined below. */ registries?: pulumi.Input[]>; /** * The maximum number of times a replica is allowed to retry. */ replicaRetryLimit?: pulumi.Input; /** * The maximum number of seconds a replica is allowed to run. */ replicaTimeoutInSeconds: pulumi.Input; /** * The name of the resource group in which to create the Container App Job. Changing this forces a new resource to be created. */ resourceGroupName: pulumi.Input; /** * A `scheduleTriggerConfig` block as defined below. Changing this forces a new resource to be created. * * > **Note:** Only one of `manualTriggerConfig`, `eventTriggerConfig` or `scheduleTriggerConfig` can be specified. */ scheduleTriggerConfig?: pulumi.Input; /** * One or more `secret` blocks as defined below. */ secrets?: pulumi.Input[]>; /** * A mapping of tags to assign to the resource. */ tags?: pulumi.Input<{ [key: string]: pulumi.Input; }>; /** * A `template` block as defined below. */ template: pulumi.Input; /** * The name of the workload profile to use for the Container App Job. */ workloadProfileName?: pulumi.Input; }