template-test1/.freeleaps/devops/web-server.Dockerfile
2025-11-12 07:33:43 +00:00

24 lines
605 B
Docker

# Use nginx alpine as base image
FROM nginx:stable-alpine
# Install envsubst
RUN apk add --no-cache gettext
# Copy pre-built dist files into nginx
COPY dist /usr/share/nginx/html
# Copy nginx configuration template and entry script
COPY nginx/default.conf /etc/nginx/conf.d/default.conf.template
COPY docker-entrypoint.sh /docker-entrypoint.sh
# Make the entry script executable
RUN chmod ug+x /docker-entrypoint.sh
# Set default environment variable
ENV API_SERVER_URL=http://api-server:8888/
# Expose port 80
EXPOSE 80
# Use the entry script as the entrypoint
ENTRYPOINT ["/docker-entrypoint.sh"]