mirror of
https://github.com/kuhyx/WUT_Computer_Science.git
synced 2026-11-11 15:33:56 +01:00
feat: make website actually display something
This commit is contained in:
parent
34ae98a912
commit
e35b578120
20
Dockerfile
20
Dockerfile
@ -1,15 +1,11 @@
|
|||||||
FROM node:latest
|
# Use the official Nginx image from the Docker Hub
|
||||||
|
FROM nginx:alpine
|
||||||
|
|
||||||
# Create app directory
|
# Copy the static website file into the Nginx server directory
|
||||||
WORKDIR /usr/src/app
|
COPY index.html /usr/share/nginx/html/index.html
|
||||||
|
|
||||||
# Install app dependencies
|
# Expose port 80
|
||||||
|
EXPOSE 80
|
||||||
|
|
||||||
# If you also need http-server globally
|
# Start Nginx and keep it running in the foreground
|
||||||
RUN npm install -g http-server
|
CMD ["nginx", "-g", "daemon off;"]
|
||||||
|
|
||||||
# Bundle app source
|
|
||||||
COPY . .
|
|
||||||
|
|
||||||
EXPOSE 8080
|
|
||||||
CMD ["http-server", "-p 8080"]
|
|
||||||
|
|||||||
9
index.html
Normal file
9
index.html
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>Hello World</title>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<h1>Hello world</h1>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
Loading…
Reference in New Issue
Block a user