-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile
More file actions
33 lines (27 loc) · 863 Bytes
/
Dockerfile
File metadata and controls
33 lines (27 loc) · 863 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# Pull base image
FROM debian:latest
# Dockerfile Maintainer
LABEL maintainer="Osama Elshazly"
# Install nginx and adjust nginx config to stay in foreground
RUN apt-get update && apt-get install --no-install-recommends -y nginx
# Create index.html using echo command
RUN echo '<!DOCTYPE html> \
<html lang="en"> \
<head> \
<meta charset="UTF-8"> \
<meta name="viewport" content="width=device-width, initial-scale=1.0"> \
<title>My Echo Web Server</title> \
</head> \
<body> \
<h1>Hamada is the leader</h1> \
<h2>Hamada is the second leader</h2> \
<h3>Hamada is the third leader</h3> \
<h1>Welcome to my Echo web server!</h1> \
<p>This is a simple HTML page served by Echo.</p> \
</body> \
</html>' > /var/www/html/index.html
COPY t.html /var/www/html/
# Expose HTTP
EXPOSE 80
# Start nginx
CMD ["nginx", "-g", "daemon off;"]