What impact has EXPOSE in the Dockerfile for OpenShift 3?

Solution In Progress - Updated -

Issue

  • We built apache web server on port 8080, deployed the same and configured service and route accordingly on port 8080.
  • Then updated apache configuration to listen on port 8084. But I kept EXPOSE 8080 in Dockerfile. Updated the image and then had to adjust service to point to 8084. After that, everything was still working.
  • Why httpd is configured to listen on port 8084? Docker should only expose 8080?

Environment

  • OpenShift Container Platform
    • 3.3

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content