I am new to these technologies and trying to figure things out. So, I followed the basic tutorials provided by Mesosphere and was able to create a cluster locally (two VMs) now I want to deploy a nodejs application so I created a docker image which contains nodejs express framework and a script which just start the server. You can find the docker image at docker registry as pujariamol/nodejs-express and it has a script at root level called as runScript.sh.
The JSON that I tried for deploying it is as follows:
{
"id": "app4",
"container": {
"type":"DOCKER",
"docker": {
"image": "pujariamol/nodejs-express"
}
},
"cmd":"echo hello > /tmp/out.txt",
"cpus": 0.25,
"mem": 512.0,
"instances": 1
}
I thought this will pull my docker container and will start it. Also, I wanted to run runScript.sh so I was trying './runScript.sh' in cmd but it didn't work so I tried writing some text in out.txt for testing purpose but nothing seems to work. The moment the application is deployed the mesos shows Failed status for this app. I am using chrome extension postman for deploying it on marathon. I have no idea what is going wrong. Please help me with getting this application deployed on Marathon and let me know if you need any more information.
Thanks in advance.