CLI command | add-application-policy |
Description | Add an application policy. |
Command format | add-application-policy -p <JSON_FILE_PATH> The path to the JSON file that defines the application policy needs to be defined as the |
Short option | Long option | Description | Required | Example value |
---|---|---|---|---|
-p | --resource-path | Folder path where the JSON file that defines the application policy is stored. | yes | <STRATOS_SOURCE_HOME>/samples/application-policies /application-policy-1.json |
{ "id": "application-policy-1", "algorithm": "one-after-another", "networkPartitions": [ "network-partition-1" ], "properties": [ { "name": "key-1", "value": "value-1" }, { "name": "key-2", "value": "value-2" } ] }
For information on all the properties that can be used in an application policy definition, see the Application Policy Resource Definition.
Use case: Add the application policy defined in the <STRATOS_SOURCE_HOME>/samples/application-policies/application-policy-1.json
file.
add-application-policy -p <STRATOS_SOURCE_HOME>/samples/application-policies/application-policy-1.json
Successfully added application policy