There is no flexible/dynamic way to ensure that a particular task runs on
every agent in the cluster.

If you are ok with static configuration, you can set aside resources for a
role on every agent by using the resources flag (e.g,
--resources="cpus(system):2;cpus(*): 10" on an agent with 12 cpus). You can
then start marathon with "system" role and ensure that only system tasks
are submitted with that role in their app config.

On Sat, May 21, 2016 at 6:26 PM, Scott Kinney <[email protected]> wrote:

> Hi Guangya,
>
> That doens't deploy the apps automatically to every slave. only one slave
> will get one of each.
>
>
>
> ------------------------------
> Scott Kinney | DevOps
> stem  <http://www.stem.com/>  |   *m*  510.282.1299
> 100 Rollins Road, Millbrae, California 94030
>
> This e-mail and/or any attachments contain Stem, Inc. confidential and
> proprietary information and material for the sole use of the intended
> recipient(s). Any review, use or distribution that has not been expressly
> authorized by Stem, Inc. is strictly prohibited. If you are not the
> intended recipient, please contact the sender and delete all copies. Thank
> you.
> ------------------------------
> *From:* Guangya Liu <[email protected]>
> *Sent:* Saturday, May 21, 2016 6:21 PM
> *To:* [email protected]
> *Subject:* Re: Setting constraints
>
> Hi Scott,
>
> I think only setting "constraints": [["hostname", "UNIQUE"] is good
> enough, please refer to
> https://github.com/mesosphere/marathon/blob/master/docs/docs/constraints.md#unique-operator
>
> Thanks,
>
> Guangya
>
> On Sun, May 22, 2016 at 12:59 AM, Scott Kinney <[email protected]>
> wrote:
>
>> I would like to have one instance of consul and registrator running on
>> every slave. I thought that by setting a attribute on every node then
>> setting contraints like..
>>
>>
>> "constraints": [
>>         ["exec_env", "GROUP_BY"],
>>         ["hostname", "UNIQUE"]
>>     ]
>> If every node has the same 'exec_env' then they would all get one
>> instance of this task ( i am not setting a value for 'instances' btw).
>>
>>
>> What is a good way to be sure every slave has one of a particular task?
>>
>> Thanks!
>>
>> ------------------------------
>> Scott Kinney | DevOps
>> stem  <http://www.stem.com/>  |   *m*  510.282.1299
>> 100 Rollins Road, Millbrae, California 94030
>>
>> This e-mail and/or any attachments contain Stem, Inc. confidential and
>> proprietary information and material for the sole use of the intended
>> recipient(s). Any review, use or distribution that has not been expressly
>> authorized by Stem, Inc. is strictly prohibited. If you are not the
>> intended recipient, please contact the sender and delete all copies. Thank
>> you.
>>
>
>

Reply via email to