Re: pcf_dev


Anwar Chirakkattil <ambumon786@...>
 

Hi Harneet,

There are certain limitations when you push a docker image to cloud foundry. As per the docs :

"By default, apps listen for connections on the port specified in the PORT environment variable for the app. Cloud Foundry allocates this value dynamically.

When configuring a Docker image for Cloud Foundry, you can control the exposed port and the corresponding value of PORT by specifying the EXPOSE directive in the image Dockerfile. If you specify the EXPOSE directive, then the corresponding app pushed to Cloud Foundry listens on that exposed port. For example, if you set EXPOSE to 7070, then the app listens for connections on port 7070.

If you do not specify a port in the EXPOSE directive, then the app listens on the value of the PORT environment variable as determined by Cloud Foundry.

If you set the PORT environment variable via an ENV directive in a Dockerfile, Cloud Foundry overrides the value with the system-determined value.

Cloud Foundry supports only one exposed port on the image." 

So, in your case, make sure that your image exposes the correct port which can be accessed from outside.

Thanks,
Anwar


Join cf-dev@lists.cloudfoundry.org to automatically receive all group messages.