Id of application that will be managed by the distribution.
Number of application-instances that need to be running.
Distribution is highly recommended for production environment. It can automatically handle amount of instances that can be changed at any moment.
There is a few options to create distribution
Create distribution using CLI
onteoncli distribution create --application-id=<application-id> --number-of-instances=<number-of-application-instances>
Create distribution using CLI - with distribution file.
First, you need to create yaml file that describes distribution. Example file:
application: <application-id> numberOfInstances: <number-of-application-instances> scripts: checkIfNodeCanAcceptNewApplicationInstance: <name-of-script OPTIONAL> selectNodeForNewApplicationInstance: <name-of-script OPTIONAL> selectApplicationInstanceToRemove: <name-of-script OPTIONAL>
Then, execute command:
onteoncli distribution create-from-file <distribution-file>
Create distribution using http API
If you want to create distribution via http api, you can send POST request to
For more information, click here.
You can always modify you distribution. E.q. you can easily change the number of instances by
onteoncli distribution set-number-of-instances <id> <newNumberOfInstances>. Environment will be updated
during the next rescheduling. You can set when the rescheduling job should
start here, by specifying cron expression.