Commands for apps
When we call the wladm Ant task, we can include various commands for apps.
The list-apps command
The list-apps command returns a list of the apps that are deployed in a runtime. It has the following attributes:
Attribute Description Required Default runtime Name of the runtime web application / MobileFirst project. Yes Not available output Name of output file. No outputproperty Name of Ant property for the output. No Example:
<list-apps runtime="worklight"/>
This command is based on the Applications (GET) REST service.
The deploy-app command
The deploy-app command deploys an app (possibly with multiple environments) in a runtime. It has the following attributes:
Attribute Description Required Default runtime Name of the runtime web application / MobileFirst project. Yes Not available file Binary app file (.wlapp, not .apk, or .ipa). Yes Not available Example:
<deploy-app runtime="worklight" file="MyApp-all.wlapp"/>
This command is based on the Application (POST) REST service.
The show-app command
The show-app command returns a list of the apps that are deployed in a runtime. It has the following attributes:
Attribute Description Required Default runtime Name of the runtime web application / MobileFirst project. Yes Not available name Name of an app. Yes Not available output Name of output file. No outputproperty Name of Ant property for the output. No Example:
<show-app runtime="worklight" name="MyApp"/>
This command is based on the Application (GET) REST service.
The delete-app command
The delete-app command removes (undeploys) an app, with all its app versions, for all environments for which it was deployed, from a runtime. It has the following attributes:
Attribute Description Required Default runtime Name of the runtime web application / MobileFirst project. Yes Not available name Name of an app. Yes Not available Example:
<delete-app runtime="worklight" name="MyApp"/>
This command is based on the Application (DELETE) REST service.
The delete-app-version command
The delete-app-version command removes (undeploys) an app version from a runtime. It has the following attributes:
Attribute Description Required Default runtime Name of the runtime web application / MobileFirst project. Yes Not available name Name of an app. Yes Not available environment Mobile platform. Yes Not available version Version of the app. Yes Not available Example:
<delete-app-version runtime="worklight" name="MyApp" environment="android" version="1.1"/>
This command is based on the App Version (DELETE) REST service.
The app-version command group
The app-version command group has the following attributes:
Attribute Description Required Default runtime Name of the runtime web application / MobileFirst project. Yes Not available name Name of an app. Yes Not available environment Mobile platform. Yes Not available version Version of the app. Yes Not available It supports the following elements:
Element Description Count get-binary Gets the binary data. 0..∞ get-accessrule Gets the access rule. 0..∞ set-accessrule Changes the access rule. 0..∞ get-authenticitycheckrule Gets the authenticity check rule. 0..∞ set-authenticitycheckrule Changes the authenticity check rule. 0..∞ get-lock Gets the lock state. 0..∞ set-lock Changes the lock state. 0..∞
The get-binary command
The get-binary command, inside an <app-version> element, returns the binary file wlapp for a version of an app. It has the following attributes:
Attribute Description Required Default tofile Name of the output file. Yes Not available Example:
<app-version runtime="worklight" name="MyApp" environment="android" version="1.1"> <get-binary tofile="/tmp/MyApp.wlapp"/> </app-version>This command is based on the Application Binary (GET, HEAD) REST service.
The get-accessrule command
The get-accessrule command returns the access rule for an app version. It has the following attributes:
Attribute Description Required Default output Name of a file in which to store the output. No outputproperty Name of an Ant property in which to store the output. No Example:
<app-version runtime="worklight" name="MyApp" environment="android" version="1.1"> <get-accessrule output="/tmp/MyApp-accessrule.xml"/> </app-version>This command is based on the Application (GET) REST service.
The set-accessrule command
The set-accessrule command changes the access rule for an app version. It has the following attributes:
Attribute Description Required Default file Name of the input file. Yes Not available Example:
<app-version runtime="worklight" name="MyApp" environment="android" version="1.1"> <set-accessrule file="/tmp/new-accessrule.xml"/> </app-version>This command is based on the App Version Access Rule (PUT) REST service.
The get-authenticitycheckrule command
The get-authenticitycheckrule command returns the authenticity check rule for an app version. It has the following attributes:
Attribute Description Required Default output Name of a file in which to store the output. No outputproperty Name of an Ant property in which to store the output. No Example:
<app-version runtime="worklight" name="MyApp" environment="android" version="1.1"> <get-authenticitycheckrule output="/tmp/MyApp-authenticitycheckrule.txt"/> </app-version>This command is based on the Application (GET) REST service.
The set-authenticitycheckrule command
The set-authenticitycheckrule command changes the authenticity check rule for an app version. It has the following attributes:
The possible actions are:
Attribute Description Required Default action Action to perform for authenticity checking. Yes Not available
- DISABLED: Authenticity is not checked.
- IGNORED: Authenticity is checked, but not enforced. If it fails, only a warning is given and the session is authorized.
- ENABLED: Authenticity is checked and enforced.
Example:
<app-version runtime="worklight" name="MyApp" environment="android" version="1.1"> <set-authenticitycheckrule action="enabled"/> </app-version>This command is based on the App Version Authenticity Check (PUT) REST service.
The get-lock command
The get-lock command returns information about whether an app version is locked or unlocked. It has the following attributes:
Attribute Description Required Default output Name of a file in which to store the output. No outputproperty Name of an Ant property in which to store the output. No Example:
<app-version runtime="worklight" name="MyApp" environment="android" version="1.1"> <get-lock output="/tmp/MyApp-lock.txt"/> </app-version>This command is based on the Application (GET) REST service.
The set-lock command
The set-lock command sets an app version to locked or unlocked state. It has the following attributes:
The possible lock values are true and false.
Attribute Description Required Default lock New lock state. Yes Not available Example:
<app-version runtime="worklight" name="MyApp" environment="android" version="1.1"> <set-lock lock="true"/> </app-version>This command is based on the App Version Lock (PUT) REST service.
Parent topic: wladm Ant task