diff --git a/Dockerfile b/Dockerfile index 9322822..0824bba 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,14 +1,10 @@ -FROM python:3.9-slim-buster +# Use a lightweight Nginx image as the base +FROM nginx:alpine -RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y nginx - -COPY index.html /usr/share/nginx/html/index.html - -RUN sed -i 's|root /var/www/html;|root /usr/share/nginx/html;|' /etc/nginx/sites-available/default && \ - nginx -t && \ - nginx -g 'daemon off;' & \ - nginx -s reload +# Copy the index.html file into the Nginx default web directory +COPY index.html /usr/share/nginx/html/ +# Expose port 80 (which will be mapped to 5555 on the host) EXPOSE 80 -CMD ["nginx", "-g", "daemon off;"] +# Nginx already runs by default, so no CMD is needed.