Whitelisting tasks
dylanmei opened this issue · 7 comments
When using a Spark framework, many entries are created for "task-0", "task-1", and so on. These are entries I didn't want. But when using the Kafka framework, "broker-1", "broker-2" are exactly what I want. I'm interested in a way to whitelist on some level, either by the framework, a role, and/or some string pattern.
I would be interested in this as well.
We currently have many apps running through marathon. Only some of them should be registered into consul (we want to ignore test apps for instance)
@dylanmei @ChrisAubuchon @kamaradclimber what do folks think of using labels on the mesos task?
https://issues.apache.org/jira/browse/MESOS-2120
For example, a marathon task.json would have:
"labels": {
"dns-register": "false"
},
or
"labels": {
"dns-register": "true"
"dns-name": "spark-worker"
},
I'm not sure if marathon labels manifest themselves as mesos task meta-data. But even if they do, Spark and other frameworks don't support this concept.
I assume the whitelisting would be part of the mesos-consul setup via config/env, or through consul kv.
agreed with @dylanmei, marathon apps are handled by our users who can put whatever they want.
We would prefer to control the whilelist on the mesos-consul side.
Branch feature/whitelist adds a --whitelist
option to the command line and takes a regular expression argument. It can be specified multiple times. For example: mesos-consul --whitelist=broker-.* --whitelist=mesos-consul
@ChrisAubuchon This is great, I'll try this out within a couple days!
Just tested it, it works great, thanks @ChrisAubuchon