Skip to content

Instantly share code, notes, and snippets.

@cicorias
Last active April 5, 2024 08:40
Show Gist options
  • Save cicorias/7613649bae43ddeabd6a07fb4027dc3b to your computer and use it in GitHub Desktop.
Save cicorias/7613649bae43ddeabd6a07fb4027dc3b to your computer and use it in GitHub Desktop.
Simple HTTP server in Docker
###
FROM mhart/alpine-node
RUN npm install -g http-server
WORKDIR /site
ADD ./ /site
# The default port of the application
EXPOSE 8080
CMD ["http-server", "--cors", "-p8080", "/site"]
@Swarag-N
Copy link

docker build -f Dockerfile -t my-health-app . && docker run -d -p 8080:8080 my-health-app

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment