Add SSL support in Docker setup and expose port 443
This commit is contained in:
parent
e630845805
commit
2bf598816e
2 changed files with 7 additions and 2 deletions
|
@ -4,6 +4,7 @@ services:
|
||||||
ports:
|
ports:
|
||||||
- 5000:5000
|
- 5000:5000
|
||||||
- 80:80
|
- 80:80
|
||||||
|
- 443:443
|
||||||
volumes:
|
volumes:
|
||||||
- .:/code
|
- .:/code
|
||||||
networks:
|
networks:
|
||||||
|
|
|
@ -5,7 +5,11 @@ RUN npm i && npm run build
|
||||||
|
|
||||||
FROM debian:stable-slim
|
FROM debian:stable-slim
|
||||||
RUN apt-get update && apt-get install -y apache2 openssl ca-certificates \
|
RUN apt-get update && apt-get install -y apache2 openssl ca-certificates \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/* \
|
||||||
WORKDIR /var/www/html
|
&& a2enmod ssl && a2ensite default-ssl
|
||||||
|
COPY 000-default.conf /etc/apache2/sites-available/000-default.conf
|
||||||
|
COPY default-ssl.conf /etc/apache2/sites-available/default-ssl.conf
|
||||||
|
WORKDIR /app
|
||||||
COPY --from=build /app/dist .
|
COPY --from=build /app/dist .
|
||||||
|
|
||||||
CMD ["apache2ctl", "-D", "FOREGROUND"]
|
CMD ["apache2ctl", "-D", "FOREGROUND"]
|
Loading…
Add table
Add a link
Reference in a new issue