I want configure/connect marathon-lp with simple web page running on mesos/maraton.
The final result what I want to obtain is web page running on one IP address and another user question should by distributed to next instance of application.
About my infrastructure
- three node mesos-master and three mesos-slave,
- in my LAN infrastrutuce I have DNS ActiveDirectory domain
Now I run example www application in mesos/marathon:
{
"id": "/example-www/hello-world",
"cmd": null,
"cpus": 0.5,
"mem": 64,
"disk": 0,
"instances": 4,
"container": {
"type": "DOCKER",
"volumes": [],
"docker": {
"image": "tutum/hello-world",
"network": "BRIDGE",
"portMappings": [
{
"containerPort": 80,
"hostPort": 0,
"servicePort": 10010,
"protocol": "tcp",
"labels": {}
}
],
"privileged": false,
"parameters": [],
"forcePullImage": true
}
},
"healthChecks": [
{
"path": "/",
"protocol": "HTTP",
"portIndex": 0,
"gracePeriodSeconds": 10,
"intervalSeconds": 2,
"timeoutSeconds": 10,
"maxConsecutiveFailures": 10,
"ignoreHttp1xx": false
}
],
"labels": {
"HAPROXY_GROUP": "external",
"HAPROXY_0_VHOST": "service.mesosphere.com",
"HAPROXY_0_BIND_ADDR": "192.168.18.9",
"HAPROXY_0_PORT": "80"
},
"portDefinitions": [
{
"port": 10010,
"protocol": "tcp",
"labels": {}
}
]
}
This web application works properly - http://oi66.tinypic.com/27y8qco.jpg
Now I want assign this web application IP address for example 192.168.18.9. The application should be available at this address IP. But when I put this address in Web Browser and I refresh the page I should be distributed for all application instance (four instance of web application).
I try configure marathon-lp but I don't know what I do wrong. In one of master node (192.168.18.10) I install dcos and marathon-lb.
My steps:
running web application in mesos/marathon
in one of mesos-master node (192.168.18.10) where dcos and marathon-lb is installed I create options.json file with content
{ "marathon-lb":{ "name":"example-www/lb", "haproxy-group":"example-www", "bind-http-https":false, "role":"" } }
Now when I exercise in ssh console
dcos package install --options=options.json marathon-lb
Status of marathon-lp application is still Waiting - screen
I read marathon-lp documentation, I try fix it for many way but every time the marathon-lp application has waiting status.
What I do wrong? Maybe I don't write required variable when I create option.json file? Or maybe this file is unnecessary?
I will be very thankful for your help.