## 6.2.5.1.3.4.2  Multitarget Application Commands for the Cloud Foundry Environment
A list of additional commands to deploy multitarget applications (MTA) to the Cloud Foundry environment.
##  Note
The expiration time for all MTA operations in Cloud Foundry is 3 days. If an operation is still active when time limit is reached, it is automatically aborted.
##  Caution
If you are using a version of the MultiApps CF CLI plugin that is older than 3.0.0, you need to make some additional configuration for deployments in regions China (Shanghai) and China (North 3). See MTA Deployment in Regions China (Shanghai) and China (North 3) [page 730].
Commands for the Cloud Foundry Environment Overview
| Command               | Alias   | Description                                                                            |
|-----------------------|---------|----------------------------------------------------------------------------------------|
| deploy                |         | Deploy a new Multitarget Application (MTA) or synchronize changes to an existing MTA.  |
| bg-deploy             |         | Deploy a Multitarget Application using 'blue-green' (zero-downtime) de- ployment.      |
| undeploy              |         | Undeploy a Multitarget Application (MTA).                                              |
| mta                   |         | Display information about a deployed Multitarget Application (MTA).                    |
| mtas                  |         | List all deployed Multitarget Applications (MTA).                                      |
| mta-ops               |         | List all active operations for Multitarget Applications.                               |
| download-mta-op- logs | dmol    | Download the log files for one or more operations concerning Multitarget Applications. |
| purge-mta-config      |         | Purge all configuration entries and subscriptions, which are no longer valid.          |
##  Note
By default, large multitarget applications are not uploaded as a single unit, but are split up into smaller chunks of 45 MBs that are uploaded separately. Configure the chunk size as described in Configuration .
## deploy
Deploy a new MTA or synchronize changes to an existing one. You have the following options for doing this:
## Usage
- Deployment using a path to a directory
You have the option to deploy or synchronize an MTA, the source of which is contained in a local directory:
```
cf deploy MTA_ARCHIVE | DIRECTORY_PATH [-e EXT_DESCRIPTOR[,...]] [-t TIMEOUT] [--version-rule VERSION_RULE] [-u URL] [-f] [--retries RETRIES] [--no-start] [--namespace NAMESPACE] [--apply-namespace-app-names true/false] [--apply-namespace-service-names true/false] [--apply-namespace-app-routes true/false] [--apply-namespace-as-suffix true/ false ] [--delete-services] [--delete-service-keys] [--delete-service-brokers] [-keep-files] [--no-restart-subscribed-apps] [--do-not-fail-on-missing-permissions] [-abort-on-error] [--strategy STRATEGY] [--skip-testing-phase] [--skip-idle-start] [--appsstart-timeout TIMEOUT] [--apps-stage-timeout TIMEOUT] [--apps-upload-timeout TIMEOUT] [--apps-taskexecution-timeout TIMEOUT]
```
## · Deployment using a URL to the MTA archive
You have the option to deploy or synchronize an MTA, the source of which is contained at a URL address. When you use this command, the request prompts the backend to download the archive and then dеploy it:
```
<write MTA archive URL to STDOUT> | cf deploy [-e EXT_DESCRIPTOR[,...]] [-t TIMEOUT] [--version-rule VERSION_RULE] [-u MTA_CONTROLLER_URL] [--retries RETRIES] [--no-start] [--namespace NAMESPACE] [--apply-namespace-app-names true/false] [--applynamespace-service-names true/false] [--apply-namespace-app-routes true/false] [--apply-namespace-as-suffix true/ false ] [--delete-services] [--delete-service-keys] [--delete-service-brokers] [--keep-files] [--norestart-subscribed-apps] [--do-not-fail-on-missing-permissions] [--abort-on-error] [--strategy STRATEGY] [--skip-testing-phase] [--skip-idle-start] [--apps-start-timeout TIMEOUT] [--apps-stage-timeout TIMEOUT] [--apps-upload-timeout TIMEOUT] [--apps-task-execution-timeout TIMEOUT]
```
##  Note
- The URL to the MTA archive must include the &lt;https://&gt; prefix.
- You can use a locally present extension descriptor along with this deployment method.
##  Restriction
The feature has the following limitations:
- There is no possibility for you to check if there are any ongoing operations on the MTA that you want to deploy using a URL.
- The remote URL must have a standard PKI certificate. It is not possible to use self-signed certificates.
- The URL cannot point to a protected GitHub URL, as GitHub does not support Basic authentication.
## · Deployment from your current directory
You have the option to deploy the content of the directory you are currently in. The MultiApps CLI plugin packages the content in accordance with the deployment descriptor definition, so that the Cloud Deployment service can then upload and deploy the MTA.
```
cf deploy [-e <EXT_DESCRIPTOR_1>[,<EXT_DESCRIPTOR_2>]] [-u <URL>] [-t <TIMEOUT>] [-v <VERSION_RULE>] [--no-start] [--namespace] [--delete-services] [--delete-service-keys] [--delete-service-brokers] [][--keep-files] [--no-restart-subscribed-apps] [--do-not-fail-on-missingpermissions] [--skip-idle-start] cf deploy ...[--retries <RETRIES>]
```
In addition to deployment, you can also interact with an active MTA deploy operation, for example, by performing an action:
```
cf deploy  [-i <OPERATION_ID>] [-a <ACTION>]
```
## Arguments
Based on the contents of the mtad.yaml descriptor, the Cloud Deployment service assembles an MTA archive in that directory before deploying it.
Command Arguments Overview
| Argument         | Description                                                                                                                                                                                                                                                                                                                                                                                                                               |
|------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| <MTA_ARCHIVE>    | The path to (and name of) the archive or the directory containing the Multitarget Application to deploy; the application archive must have the format (and file ex- tension) mtar , for example, MTApp1.mtar . If the value of this argument is a directory, the checks if an mtad.yaml file exists in that directory, and based on it assembles an MTAarchive before deploying it. If no argument exists, the current directory is used. |
| <DIRECTORY_PATH> | The Cloud Deployment service also accepts a path to a directory where an mtad.yaml is maintained with path elements, for example, cf deploy ./ .                                                                                                                                                                                                                                                                                          |
| <--retries>      | Retry the operation specified number of times in case a non-content error (default 3).                                                                                                                                                                                                                                                                                                                                                    |
## Options
Command Options Overview
## Option
## Description
| -e <EXT_DESCRIPTOR_1>[,<EXT_DESCRIPTOR _2>]   | Define one or more extensions to the deployment descriptors; multi- ple extension descriptors must be separated by commas.   |
|-----------------------------------------------|------------------------------------------------------------------------------------------------------------------------------|
| Option                                  | Description                                                                                                                                                                                          |
|-----------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| -u <URL>                                | Specify the URL for the deployment-service end-point that is to be used for the deployment operation.                                                                                                |
| -t <TIMEOUT>                            | Specify the maximum amount of time (in seconds) that the service must wait for before starting the deployed application.                                                                             |
| -v <VERSION_RULE>                       | Specify the rule to apply to determine how the application version number is used to trigger an application-update deployment opera- tion, for example: ' HIGHER ', ' SAME_HIGHER ', or ' ALL '.     |
| -i <OPERATION_ID>                       | Specify the ID of the deploy operation that you want to perform an action on.                                                                                                                        |
| -a <ACTION>                             | Specify the action to perform on the deploy operation, for example, 'abort', 'retry', or 'monitor', or 'resume'.                                                                                     |
| -f                                      | Force deployment without requiring any confirmation about aborting any conflicting processes.                                                                                                        |
| --no-start                              | Do not start application after deployment.                                                                                                                                                           |
| --apps-upload-timeout <TIMEOUT>         | Defines how long, in seconds, you can upload your application binary before the MTAoperation times out.                                                                                              |
| --apps-stage-timeout <TIMEOUT>          | Defines how long, in seconds, your application can take during stag- ing before the MTAoperation times out. See Application-Specific Timeouts [page 671] .                                           |
| --apps-start-timeout <TIMEOUT>          | Defines how long, in seconds, your application can take to start be- fore the MTAoperation times out. See Application-Specific Timeouts [page 671] .  Note This applies to all applications.        |
| --apps-task-execution-timeout <TIMEOUT> | Defines how long, in seconds, your application can take to execute a task before the MTAoperation times out. See Application-Specific Timeouts [page 671] .  Note This applies to all applications. |
| Option                                | Description                                                                                                                                                                                                                                                                                             |
|---------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| --delete-services                     | Re-create changed services and delete discontinued services.                                                                                                                                                                                                                                            |
| --delete-service-keys                 | Delete the existing service keys and apply the new ones.                                                                                                                                                                                                                                                |
| --delete-service-brokers              | Delete discontinued service brokers.                                                                                                                                                                                                                                                                    |
| --keep-files                          | Keep the files used for deployment.                                                                                                                                                                                                                                                                     |
| --no-restart-subscribed-apps          | Do not restart subscribed applications that are updated during the deployment.                                                                                                                                                                                                                          |
| --do-not-fail-on-missing- permissions | Perform the deployment, even if required administrator permissions are missing for some operations (for example, the creation of service brokers).                                                                                                                                                      |
| --abort-on-error                      | If an operation fails, the corresponding process is automatically aborted and cannot be retried using the option -a retry. However, if you run a new operation for the same MTA, you will not receive an error message that there is an ongoing process for the MTAand ask you if you want to abort it. |
| -m <module name>                      | Deploy only the module with the specified name.                                                                                                                                                                                                                                                         |
| --all-modules                         | Deploy all modules.                                                                                                                                                                                                                                                                                     |
| -r <resource name>                    | Deploy only the resource with the specified name  Note It can be used multiple times.                                                                                                                                                                                                                  |
| --all-resources                       | Deploy all resources.  Note                                                                                                                                                                                                                                                                            |
| Option                                                    | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
|-----------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| --strategy                                                | Announce to the platform a special deployment approach, for exam- ple when performing a 'blue-green' or an 'incremental-blue-green' deployment. See Blue-Green Deployment Strategy [page 708] and (Experimental) Incremental Blue-Green Deployment Strategy [page 711]. Using this option, you will not be asked to manually confirm the deletion of the older version of the MTAapplications. This means that the deployment process is performed without any interruptions and you are not prompted to confirm the switch of routes to the new version of the MTAapplications. |
| --skip-testing-phase                                      | When using the --strategy option for 'blue-green' or 'incremental- blue-green' deployment, you can choose to skip the testing phase and you will not be asked to manually confirm the deletion of the older version of the MTAapplications. The deployment process is performed without any interruptions and you are not prompted to confirm the switch of routes to the new version of the MTAapplica- tions.                                                                                                                                                                  |
| --namespace  Note This option is currently experimental. | Namespace for the MTA. They are also applied to the application and service names. For more information, see (Experimental) Namespa- ces [page 714].                                                                                                                                                                                                                                                                                                                                                                                                                             |
| --apply-namespace-app-names true/ false                   | Apply namespace to application names. If the namespace value is not provided in the CLI options, it is not applied.                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
|  Note This option is currently experimental.             |  Note This applies to all applications.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| --apply-namespace-service-names true/false                | Apply namespace to service names. If the namespace value is not provided in the CLI options, it is not applied.                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
|  Note This option is currently experimental.             |  Note This applies to all services.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| --apply-namespace-app-routes true/ false                  | Apply namespace to application routes. If the namespace value is not provided in the CLI options, it is not applied.                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
|  Note This option is currently experimental.             |  Note This applies to all application routes.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
## Option
| --apply-namespace-as-suffix true/ false       | Apply namespace as suffix. If the namespace value is not provided in the CLI options, it is not applied.                                                                                                                                                                      |
|-----------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|  Note This option is currently experimental. |  Note This applies to                                                                                                                                                                                                                                                        |
| --skip-idle-start                             | all applications, services, and application routes.                                                                                                                                                                                                                           |
|                                               | When using the --strategy option for 'blue-green', you can choose to skip the starting of the newly deployed applications on idle routes. This means that the newly deployed applications will be mapped directly to live routes. Under the hood this option includes --skip- |
|  Note                                        |                                                                                                                                                                                                                                                                               |
| This option is currently experimental.        | testing-phase.                                                                                                                                                                                                                                                                |
##  Note
- If any of the options -m , --all-modules , -r , --all-resource is used, only the specified modules and resources will be deployed. Otherwise, everything will be deployed by default.
- If the options for the module deploying ( -m , --all-modules ) are used, the modules need to contain a path element on an MTA module level, which points to the content of the module. In case the module has some requires dependency section to a resource that needs a configuration file, then the requires section should have a path parameter, which points to the configuration file.
- If the options for the resource deploying ( -r , --all-resource ) are used, then any resources that have some configuration files need to contain a path parameter in their parameters section, which points to the configuration file.
- The path element or parameter value should be relative to the MTA directory.
An example of an MTA deployment descriptor, containing all variants of the path elements and parameters can be found at Defining Multitarget Application Deployment Descriptors for Cloud Foundry [page 606].
## bg-deploy
Deploy a new Multitarget Application (MTA) using 'blue-green' (zero-downtime) deployment.
##  Note
You can also perform this deployment type using the deploy command by using the experimental --strategy blue-green flag. See above for details.
'Blue-green' deployment is a release technique that reduces application downtime and the resulting risk by running two identical target deployment environments called 'blue' and 'green'. Only one of the two target environments is 'live' at any point in time and it is much easier to roll back to a previous version after a failed (or undesired) deployment.
## Usage
Deploy a new Multitarget Application using 'blue-green' deployment:
```
cf bg-deploy <MTA_ARCHIVE> [-e <EXT_DESCRIPTOR_1>[,<EXT_DESCRIPTOR_2>]]
```
## Description
```
[-u <URL>] [-t <TIMEOUT>] [-v <VERSION_RULE>] [--no-start] [--use-namespaces] [--no-namespaces-for-services] [--delete-services] [--delete-service-keys] [--delete-service-brokers] [--keep-files] [--no-restart-subscribed-apps] [--no-confirm] [--do-not-fail-onmissing-permissions][--skip-idle-start] cf deploy ...[--retries <RETRIES>]
```
Interact with an active MTA deploy operation, for example, by performing an action:
```
cf bg-deploy  [-i <OPERATION_ID>] [-a <ACTION>]
```
## Arguments
Command Arguments Overview
| Argument                          | Description                                                                                                                                                                                                                                                                                                                |
|-----------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| <MTA_ARCHIVE> or <DIRECTORY_PATH> | The path to (and name of) the archive or the path to the directory containing the Multitarget Application to deploy. The application archive must have the format (and file extension) mtar , for example, MTApp1.mtar ; the specified directory can be specified as a path (for example, myApp/ or . (current directory). |
| <--retries>                       | Retry the operation specified number of times in case a non-content error (default 3).                                                                                                                                                                                                                                     |
## Options
Command Options Overview
| Option                                      | Description                                                                                                                                                                                      |
|---------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| -e <EXT_DESCRIPTOR_1>[,<EXT_DESCRIPTOR _2>] | Define one or more extensions to the deployment descriptors; multi- ple extension descriptors must be separated by commas.                                                                       |
| -u <URL>                                    | Specify the URL for the deployment-service end-point that is to be used for the deployment operation.                                                                                            |
| -t <TIMEOUT>                                | Specify the maximum amount of time (in seconds) that the service must wait for before starting the deployed application.                                                                         |
| -v <VERSION_RULE>                           | Specify the rule to apply to determine how the application version number is used to trigger an application-update deployment opera- tion, for example: ' HIGHER ', ' SAME_HIGHER ', or ' ALL '. |
| -i <OPERATION_ID>                           | Specify the ID of the deploy operation that you want to perform an action on.                                                                                                                    |
| -a <ACTION>                                 | Specify the action to perform on the deploy operation, for example, 'abort', 'retry', or 'monitor', or 'resume'.                                                                                 |
| -f                                          | Force deploy without requiring any confirmation for aborting any conflicting processes.                                                                                                          |
| --no-start                                  | Do not start application after deployment.                                                                                                                                                       |
| --use-namespaces                            | Use namespaces in application (and service) names during applica- tion deployment.                                                                                                               |
| --no-namespaces-for-services                | Do not use namespaces in service names.                                                                                                                                                          |
| --delete-services                           | Re-create changed services and delete discontinued services.                                                                                                                                     |
## Option
Description
<!-- image -->
| --delete-service-keys                                                                                                                                                                           | Delete the existing service keys and apply the new ones.                                                                                                                                                                                                                                    |
|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| --delete-service-brokers                                                                                                                                                                        | Delete discontinued service brokers.                                                                                                                                                                                                                                                        |
| --keep-files                                                                                                                                                                                    | Keep the files used for deployment.                                                                                                                                                                                                                                                         |
| --no-restart-subscribed-apps                                                                                                                                                                    | Do not restart subscribed applications that are updated during the deployment.                                                                                                                                                                                                              |
| --no-confirm                                                                                                                                                                                    | Use this option to turn off the manual confirmation for deleting the older version of the MTAapplications. Thus the deployment process is performed from start to finish uninterrupted, and you are not prompted to confirm the switch of routes to the new version of the MTAapplications. |
| --do-not-fail-on-missing- permissions                                                                                                                                                           | Perform the deployment, even if required administrator permissions are missing for some operations (for example, the creation of service brokers).                                                                                                                                          |
| --abort-on-error                                                                                                                                                                                | If an operation fails, the corresponding process is automatically aborted and cannot be retried using the option -a retry.                                                                                                                                                                  |
| -m <module name>. However, if you run a new operation for the same MTA, you will not receive an error message that there is an ongoing process for the MTA and ask you if you want to abort it. | Deploy only the module with the specified name.  Note It can be used multiple times.                                                                                                                                                                                                       |
| --all-modules                                                                                                                                                                                   | Deploy all modules.                                                                                                                                                                                                                                                                         |
| -r <resource name>                                                                                                                                                                              | Deploy only the resource with the specified name.  Note                                                                                                                                                                                                                                    |
| --all-resources                                                                                                                                                                                 | It can be used multiple times.                                                                                                                                                                                                                                                              |
|                                                                                                                                                                                                 | Deploy all resources.  Note Any -r options are ignored.                                                                                                                                                                                                                                    |
| --skip-idle-start  Note This option is currently experimental.                                                                                                                                 | You can choose to skip the starting of the newly deployed applica- tions on idle routes. This means that the newly deployed applications will be mapped directly to live routes. Under the hood this option includes --no-confirm.                                                          |
##  Note
- If any of the options -m , --all-modules , -r , --all-resource is used, only the specified modules and resources will be deployed. Otherwise, everything will be deployed by default.
- If the options for the module deploying ( -m , --all-modules ) are used, the modules need to contain a path element on an MTA module level, which points to the content of the module. In case the module has some requires dependency section to a resource that needs a configuration file, then the requires section should have a path parameter, which points to the configuration file.
- If the options for the resource deploying ( -r , --all-resource ) are used, then any resources that have some configuration files need to contain a path parameter in their parameters section, which points to the configuration file.
- The path element or parameter value should be relative to the MTA directory.
See the complete procedure in section Legacy Blue-Green Deployment [page 706].
An example of an MTA deployment descriptor, containing all variants of the path elements and parameters can be found at Defining Multitarget Application Deployment Descriptors for Cloud Foundry [page 606].
## undeploy
Undeploy a Multitarget Application (MTA), or interact with an undeploy MTA operation.
## Usage
Undeploy an MTA.
```
cf undeploy <MTA_ID> [-u <URL>] [-f] [--delete-services] [--delete-service-keys] [--delete-service-brokers] [--norestart-subscribed-apps] [--do-not-fail-on-missing-permissions] cf deploy ...[--retries <RETRIES>]
```
Interact with an undeploy MTA operation, for example, by performing an action.
```
cf undeploy [-i <UNDEPLOY_ID>] [-a <ACTION>]
```
## Arguments
Command Arguments Overview
Argument
Description
| <MTA_ID>    | The ID of the MTAyou want to undeploy                                                  |
|-------------|----------------------------------------------------------------------------------------|
| <--retries> | Retry the operation specified number of times in case a non-content error (default 3). |
## Options
Command Options Overview
| Option                                | Description                                                                                                                                                                                                                                                                                             |
|---------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| -u <URL>                              | Specify the URL for the service end-point that is to be used for the undeployment operation.                                                                                                                                                                                                            |
| -i <OPERATION_ID>                     | Specify the ID of the undeploy operation that you want to perform an action on.                                                                                                                                                                                                                         |
| -a <ACTION>                           | Specify the action to perform on the undeploy operation, for exam- ple, 'abort', 'retry', or 'monitor'.                                                                                                                                                                                                 |
| -f                                    | Force completion of the undeploy operation without any system prompt or confirmation.                                                                                                                                                                                                                   |
| --delete-services                     | Delete any related services.                                                                                                                                                                                                                                                                            |
| --delete-service-brokers              | Delete discontinued service brokers.                                                                                                                                                                                                                                                                    |
| --no-restart-subscribed-apps          | Do not restart subscribed applications that are updated during the deployment.                                                                                                                                                                                                                          |
| --do-not-fail-on-missing- permissions | Perform the deployment, even if required administrator permissions are missing for some operations (for example, the creation of service brokers).                                                                                                                                                      |
| --abort-on-error                      | If an operation fails, the corresponding process is automatically aborted and cannot be retried using the option -a retry. However, if you run a new operation for the same MTA, you will not receive an error message that there is an ongoing process for the MTAand ask you if you want to abort it. |
| --delete-service-keys                 | Delete the existing service keys.                                                                                                                                                                                                                                                                       |
## mta
Display information about a Multitarget Application (MTA). The information displayed includes the requested state, the number of instances, information about allocated memory and disk space, as well as details regarding the bound service (and service plan).
## Usage
```
cf mta MTA_ID [-u <URL>]
```
## Arguments
Command Arguments Overview
| Argument   | Description                                        |
|------------|----------------------------------------------------|
| <MTA_ID>   | The ID of the MTAwhose details you want to display |
## Options
Command Options Overview
## Option
## Description
| -u <URL>   | Specify the URL for the deployment-service end-point to use to ob- tain details of the selected MTA.   |
|------------|--------------------------------------------------------------------------------------------------------|
## mtas
Display information about all available Multitarget Applications (MTA).
## Usage
cf mtas [-u &lt;URL&gt;]
## Options
Command Options Overview
## Option
## Description
| -u <URL>   | Specify the URL for the deployment-service endpoint to use to ob- tain details of the selected MTA.   |
|------------|-------------------------------------------------------------------------------------------------------|
## mta-ops
Display information about all active operations for Multitarget Applications (MTA). The information includes the ID, type, status, the time the MTA-related operation started, as well as the name of the user that started the operation.
## Usage
```
cf mta-ops [--mta <MTA>] [-u <URL>] [--last <NUM>] [--all]
```
## Options
Command Options Overview
| Option       | Description                                                                                                    |
|--------------|----------------------------------------------------------------------------------------------------------------|
| -u <URL>     | Specify the URL for the deployment-service end-point to use to ob- tain details of the selected MTAoperations. |
| --last <NUM> | List the last <NUM> active MTAoperations.                                                                      |
| --all        | List all active MTAoperations.                                                                                 |
| - mta <MTA>  | Specify the MTAwhose operations you want to list.                                                              |
## download-mta-op-logs
Download the log files for one or more operations concerning Multitarget Applications.
## Usage
You have the following usage options:
```
· cf download-mta-op-logs -i <OPERATION_ID> [-u <URL>] [-d <DIRECTORY>] · cf download-mta-op-logs --mta <MTA> [ --last <NUM>] [ -u <URL>] [ -d <DIRECTORY>]
```
##  Tip
You can use the alias dmol in place of the download-mta-op-logs command.
## Options
Command Options Overview
| Option            | Description                                                                                                                                         |
|-------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------|
| -u <URL>          | Specify the URL for the deployment-service end-point to use to ob- tain details of the selected MTAoperations.                                      |
| -i <OPERATION_ID> | Specify the identity (ID) of the MTAoperation whose logs you want to download.                                                                      |
| -d <DIRECTORY>    | Specify the path to the location where you want to save the down- loaded MTAoperation logs; by default, the location is ./mta-op- <OPERATION_ID>/ . |
| --mta <MTA>       | Specify the MTAwhose logs you want to download.                                                                                                     |
|                   |  Note This option is not compatible with the -i option.                                                                                            |
| --last<NUM>       | Download the last <NUM>logs for the specified MTA.                                                                                                  |
## purge-mta-config
Purge all configuration entries and subscriptions, which are no longer valid.
## Usage
```
cf purge-mta-config [-u <URL>]
```
Invalid configuration entries are often produced when the application that is providing configuration entries is deleted by the user without using the deploy-service, for example, the cf delete command . In this case, the configuration remains in the deploy-service database even though the corresponding application is no longer available. This could lead to a failure during subsequent attempts to resolve the configuration entries.
## Options
Command Options Overview
Option
Description
| -u <URL>   | The URL of the deploy service   |
|------------|---------------------------------|
## Related Information
MultiApps CLI plugin
Cloud Foundry multitarget аpplication еxamples repository
Deploy an MTA archive referenced by a remote URL