- Layerfile Reference
- EXPOSE WEBSITE
EXPOSE WEBSITE [location on runner] (path) (rewrite path)
EXPOSE WEBSITE instruction creates a persistent link to view a webserver
running at a specific port in the Layerfile. It’s especially useful for sharing
changes with non-technical stakeholders or running manual QA/review.
EXPOSE_WEBSITE_HOST environment variable is available even
EXPOSE WEBSITE if you need to “bake” the path to the exposed website
If the default 2 minute timeout is not sufficient for your application, use the following pattern to wait until the server is ready:
EXPOSE WEBSITE localhost:80to expose the local webserver at port 80
EXPOSE WEBSITE localhost:80 /apiwith
EXPOSE WEBSITE localhost:3000 /to route all requests that start with /api to port 80 in the runner, and all other requests to port 3000.
EXPOSE WEBSITE localhost:80 /cypress$SPLITafter a
SPLIT 5directive to make each split have a unique path (e.g.,