az spring job
Note
This reference is part of the spring extension for the Azure CLI (version 2.56.0 or higher). The extension will automatically install the first time you run an az spring job command. Learn more about extensions.
This command group is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
This command group is implicitly deprecated because command group 'spring' is deprecated and will be removed in a future release.
(Enterprise Tier Only) Commands to manage jobs of Azure Spring Apps service.
Commands
| Name | Description | Type | Status |
|---|---|---|---|
| az spring job create |
Create a new job in Azure Spring Apps service. |
Extension | Preview and Deprecated |
| az spring job delete |
Delete a job in the Azure Spring Apps. |
Extension | Preview and Deprecated |
| az spring job deploy |
Deploy artifact to a job and update related configurations. |
Extension | Preview and Deprecated |
| az spring job execution |
(Enterprise Tier Only) Commands to manage job executions of Azure Spring Apps service. |
Extension | Preview and Deprecated |
| az spring job execution cancel |
Cancel a job execution. |
Extension | Preview and Deprecated |
| az spring job execution instance |
(Enterprise Tier Only) Commands to manage job execution instances of Azure Spring Apps service. |
Extension | Preview and Deprecated |
| az spring job execution instance list |
List all instances of the job execution. |
Extension | Preview and Deprecated |
| az spring job execution list |
List all executions of the job. |
Extension | Preview and Deprecated |
| az spring job execution show |
Show status and results of an execution of the job. |
Extension | Preview and Deprecated |
| az spring job list |
List all jobs in the Azure Spring Apps. |
Extension | Preview and Deprecated |
| az spring job logs |
Show logs for job execution instances. Logs will be streamed when setting '-f/--follow'. |
Extension | Preview and Deprecated |
| az spring job show |
Show the details of a job in the Azure Spring Apps. |
Extension | Preview and Deprecated |
| az spring job start |
Start an execution of the job. |
Extension | Preview and Deprecated |
| az spring job update |
Update configurations of a job. |
Extension | Preview and Deprecated |
az spring job create
Command group 'spring job' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
This command is implicitly deprecated because command group 'spring' is deprecated and will be removed in a future release.
Create a new job in Azure Spring Apps service.
az spring job create --name
--resource-group
--service
[--args]
[--bind-config-server --bind-cs]
[--bind-service-registry --bind-sr]
[--cpu]
[--envs]
[--memory]
[--parallelism]
[--retry-limit]
[--secret-envs]
[--timeout]
Examples
Create a job with the default configuration.
az spring job create -n job-name -s MyAzureSpringAppsInstance -g MyResourceGroup
Required Parameters
The name of job running in the specified Azure Spring Apps instance.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
The name of Azure Spring Apps instance, you can configure the default service using az configure --defaults spring=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
The arguments of the job execution.
Bind the job to the default Config Server automatically.
Bind the job to the default Service Registry automatically.
CPU resource quantity. Should be 500m or number of CPU cores.
| Property | Value |
|---|---|
| Default value: | 1 |
Non-sensitive properties for environment variables. Format "key[=value]" and separated by space.
Memory resource quantity. Should be 512Mi or #Gi, e.g., 1Gi, 3Gi.
| Property | Value |
|---|---|
| Default value: | 2Gi |
Maximum number of replicas to run per execution.
Maximum number of retries before failing the job.
Sensitive properties for environment variables. Once put, it will be encrypted and not returned.Format "key[=value]" and separated by space.
Maximum number of seconds an execution is allowed to run.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az spring job delete
Command group 'spring job' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
This command is implicitly deprecated because command group 'spring' is deprecated and will be removed in a future release.
Delete a job in the Azure Spring Apps.
az spring job delete --name
--resource-group
--service
Examples
Delete a job
az spring job delete -n job-name -s MyAzureSpringAppsInstance -g MyResourceGroup
Required Parameters
The name of job running in the specified Azure Spring Apps instance.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
The name of Azure Spring Apps instance, you can configure the default service using az configure --defaults spring=<name>.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az spring job deploy
Command group 'spring job' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
This command is implicitly deprecated because command group 'spring' is deprecated and will be removed in a future release.
Deploy artifact to a job and update related configurations.
az spring job deploy --name
--resource-group
--service
[--args]
[--artifact-path]
[--build-cpu]
[--build-env]
[--build-memory]
[--builder]
[--cpu]
[--disable-validation {false, true}]
[--envs]
[--memory]
[--no-wait]
[--parallelism]
[--retry-limit]
[--secret-envs]
[--source-path]
[--timeout]
[--version]
Examples
Deploy a pre-built jar to a job with environment variables.
az spring job deploy -n job-name -s MyAzureSpringAppsInstance -g MyResourceGroup --artifact-path app.jar --env foo=bar
Deploy a pre-built jar to a job with build env.
az spring job deploy -n job-name -s MyAzureSpringAppsInstance -g MyResourceGroup --artifact-path app.jar --build-env BP_JVM_VERSION=11.*
Required Parameters
The name of job running in the specified Azure Spring Apps instance.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
The name of Azure Spring Apps instance, you can configure the default service using az configure --defaults spring=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
The arguments of the job execution.
Deploy the specified pre-built artifact (jar or netcore zip).
CPU resource quantity. Should be 500m or number of CPU cores.
| Property | Value |
|---|---|
| Default value: | 1 |
Space-separated environment variables in 'key[=value]' format.
Memory resource quantity. Should be 512Mi or #Gi, e.g., 1Gi, 3Gi.
| Property | Value |
|---|---|
| Default value: | 2Gi |
(Enterprise Tier Only) Build service builder used to build the executable.
| Property | Value |
|---|---|
| Default value: | default |
CPU resource quantity. Should be 500m or number of CPU cores.
If true, disable jar validation.
| Property | Value |
|---|---|
| Accepted values: | false, true |
Non-sensitive properties for environment variables. Format "key[=value]" and separated by space.
Memory resource quantity. Should be 512Mi or #Gi, e.g., 1Gi, 3Gi.
Do not wait for the long-running operation to finish.
| Property | Value |
|---|---|
| Default value: | False |
Maximum number of replicas to run per execution.
Maximum number of retries before failing the job.
Sensitive properties for environment variables. Once put, it will be encrypted and not returned.Format "key[=value]" and separated by space.
Deploy the specified source folder. The folder will be packed into tar, uploaded, and built using kpack. Default to the current folder if no value provided.
| Property | Value |
|---|---|
| Parameter group: | Source Code deploy Arguments |
Maximum number of seconds an execution is allowed to run. You can use -1 to reset timeout.
Deployment version, keep unchanged if not set.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az spring job list
Command group 'spring job' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
This command is implicitly deprecated because command group 'spring' is deprecated and will be removed in a future release.
List all jobs in the Azure Spring Apps.
az spring job list --resource-group
--service
Examples
List jobs
az spring job list -s MyAzureSpringAppsInstance -g MyResourceGroup
Required Parameters
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
The name of Azure Spring Apps instance, you can configure the default service using az configure --defaults spring=<name>.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az spring job logs
Command group 'spring job' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
This command is implicitly deprecated because command group 'spring' is deprecated and will be removed in a future release.
Show logs for job execution instances. Logs will be streamed when setting '-f/--follow'.
az spring job logs --execution
--name
--resource-group
--service
[--all-instances]
[--follow]
[--instance]
[--limit]
[--lines]
[--max-log-requests]
[--since]
Examples
Show logs for all instances of a job execution.
az spring job logs --name job-name --execution job-execution-nam --all-instances -s MyService -g MyResourceGroup
Show logs for a specific instance of a job execution.
az spring job logs --name job-name --execution job-execution-nam --instance job-execution-instance -s MyService -g MyResourceGroup
Stream and watch logs for all instances of a job execution.
az spring job logs --name job-name --execution job-execution-nam --all-instances --follow -s MyService -g MyResourceGroup
Stream and watch logs for a specific instance of a job execution.
az spring job logs --name job-name --execution job-execution-nam --instance MyJobExecutionInstance --follow -s MyService -g MyResourceGroup
Required Parameters
The name of the job execution.
The name of the job running in the specified Azure Spring Apps instance.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
The name of Azure Spring Apps instance, you can configure the default service using az configure --defaults spring=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
The flag to indicate get logs for all instances of the job execution.
The flag to indicate logs should be streamed.
Name of an existing instance of the job execution. Find instance names from command az spring job execution instance list.
Maximum kibibyte of logs to return. Ceiling number is 2048.
| Property | Value |
|---|---|
| Default value: | 2048 |
Number of lines to show. Maximum is 10000.
| Property | Value |
|---|---|
| Default value: | 100 |
Specify maximum number of concurrent logs to follow when get logs by all-instances.
| Property | Value |
|---|---|
| Default value: | 5 |
Only return logs newer than a relative duration like 5s, 2m, or 1h. Maximum is 1h.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az spring job show
Command group 'spring job' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
This command is implicitly deprecated because command group 'spring' is deprecated and will be removed in a future release.
Show the details of a job in the Azure Spring Apps.
az spring job show --name
--resource-group
--service
Required Parameters
The name of job running in the specified Azure Spring Apps instance.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
The name of Azure Spring Apps instance, you can configure the default service using az configure --defaults spring=<name>.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az spring job start
Command group 'spring job' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
This command is implicitly deprecated because command group 'spring' is deprecated and will be removed in a future release.
Start an execution of the job.
az spring job start --name
--resource-group
--service
[--args]
[--cpu]
[--envs]
[--memory]
[--secret-envs]
[--wait-until-finished {false, true}]
Examples
Start an execution of the job
az spring job start -n job-name -s MyAzureSpringAppsInstance -g MyResourceGroup
Required Parameters
The name of job running in the specified Azure Spring Apps instance.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
The name of Azure Spring Apps instance, you can configure the default service using az configure --defaults spring=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
The arguments of the job execution.
CPU resource quantity. Should be 500m or number of CPU cores.
Non-sensitive properties for environment variables. Format "key[=value]" and separated by space.
Memory resource quantity. Should be 512Mi or #Gi, e.g., 1Gi, 3Gi.
Sensitive properties for environment variables. Once put, it will be encrypted and not returned.Format "key[=value]" and separated by space.
If true, wait until the job execution is finished.
| Property | Value |
|---|---|
| Default value: | False |
| Accepted values: | false, true |
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az spring job update
Command group 'spring job' is in preview and under development. Reference and support levels: https://aka.ms/CLI_refstatus
This command is implicitly deprecated because command group 'spring' is deprecated and will be removed in a future release.
Update configurations of a job.
az spring job update --name
--resource-group
--service
[--args]
[--cpu]
[--envs]
[--memory]
[--parallelism]
[--retry-limit]
[--secret-envs]
[--timeout]
Examples
Add plain text environment variables for the job.
az spring job update -n job-name -s MyAzureSpringAppsInstance -g MyResourceGroup --envs foo=bar
Remove all plain text environment variables and keep all existed secrets for the job.
az spring job update -n job-name -s MyAzureSpringAppsInstance -g MyResourceGroup --envs
Remove all secrets and keep all the plain text environment variables for the job.
az spring job update -n job-name -s MyAzureSpringAppsInstance -g MyResourceGroup --secret-envs
Required Parameters
The name of job running in the specified Azure Spring Apps instance.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
The name of Azure Spring Apps instance, you can configure the default service using az configure --defaults spring=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
The arguments of the job execution.
CPU resource quantity. Should be 500m or number of CPU cores.
Non-sensitive properties for environment variables. Format "key[=value]" and separated by space.
Memory resource quantity. Should be 512Mi or #Gi, e.g., 1Gi, 3Gi.
Maximum number of replicas to run per execution.
Maximum number of retries before failing the job.
Sensitive properties for environment variables. Once put, it will be encrypted and not returned.Format "key[=value]" and separated by space.
Maximum number of seconds an execution is allowed to run. You can use -1 to reset timeout.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |