unable to access helloworld App deployed using DCOS Marathon in Azure
In your example, host port
is 0, Azure will listen your service on a random port. You need open the port on NSG and lb.
I suggest you could specify the port, you could check the following example:
{ "id": "/dockercloud-hello-world", "cmd": null, "cpus": 0.1, "mem": 32, "disk": 0, "instances": 1, "acceptedResourceRoles": [ "slave_public" ], "container": { "type": "DOCKER", "volumes": [], "docker": { "image": "dockercloud/hello-world", "network": "BRIDGE", "portMappings": [ { "containerPort": 80, "hostPort": 80, "protocol": "tcp", "labels": {}, "name": "test80" } ], "privileged": false, "parameters": [], "forcePullImage": true } }, "healthChecks": [ { "gracePeriodSeconds": 10, "intervalSeconds": 2, "timeoutSeconds": 10, "maxConsecutiveFailures": 10, "portIndex": 0, "path": "/", "protocol": "MESOS_HTTP", "ignoreHttp1xx": false } ], "requirePorts": true}
Note: You should set acceptedResourceRoles
to slave_public
. More information about this please check this link.
Along with the above-mentioned JSON I need to use the agent URL to access the application. I was missing on that