From 494e19dcb72339c62adb8c0cea77f0b3522a034c Mon Sep 17 00:00:00 2001 From: Twilight <31920608+LoneTwilight@users.noreply.github.com> Date: Wed, 17 Apr 2024 18:54:04 +0800 Subject: [PATCH] Add files via upload --- challenges/web/Dockerfile | 18 ++++++++++++++++++ challenges/web/README.md | 3 ++- 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 challenges/web/Dockerfile diff --git a/challenges/web/Dockerfile b/challenges/web/Dockerfile new file mode 100644 index 0000000..424e3b4 --- /dev/null +++ b/challenges/web/Dockerfile @@ -0,0 +1,18 @@ +FROM debian:latest +RUN apt update && apt install -y nginx + +COPY ./warmweb/ /var/www/html +COPY ./warmwebconf/default /etc/nginx/conf.d/ + +RUN rm /etc/nginx/sites-enabled/default +RUN echo "server {" > /etc/nginx/conf.d/default.conf && \ +echo " listen 52001;" >> /etc/nginx/conf.d/default.conf && \ +echo " location / {" >> /etc/nginx/conf.d/default.conf && \ +echo " root /var/www/html;" >> /etc/nginx/conf.d/default.conf && \ +echo " index index.html index.htm;" >> /etc/nginx/conf.d/default.conf && \ +echo " }" >> /etc/nginx/conf.d/default.conf && \ +echo "}" >> /etc/nginx/conf.d/default.conf + +EXPOSE 52001 + +CMD ["nginx", "-g", "daemon off;"] \ No newline at end of file diff --git a/challenges/web/README.md b/challenges/web/README.md index 5739a23..9dcf684 100644 --- a/challenges/web/README.md +++ b/challenges/web/README.md @@ -1 +1,2 @@ -This dir contains challenges related to web +Challenge Name: Warmup Web +Challenge Description: Simple flag but why.html is it not showing? \ No newline at end of file