-
Notifications
You must be signed in to change notification settings - Fork 50
/
Copy pathsession-54.txt
51 lines (29 loc) · 1.08 KB
/
session-54.txt
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
volumes:
- unnamed
- named
-v host-path:container-path
docker run -d -p 80:80 -v /home/ec2-user/nginx-data:/usr/share/nginx/html nginx
1GB app
single flat 2400 sqft --> only one room --> one family
6GB apps are also running in containers
Multi stage builds --> Java apps
JDK --> Java development kit
JRE --> Java runtime environment
JDK > JRE
JDK = JRE + development tools
Developers develop java apps in JDK environment, once you get build package. no need to dev environment
app code --> compile[JDK] --> java bytecode(build file) .jar, .war [JDK]
run bytecode --> app is up [JRE]
layer1 --> FROM nginx
layer2 --> FROM nginx+RUN rm -rf /usr/share/nginx/html/index.html --> create image
create layer2 container from layer2 image
layer3 image = layer2+RUN rm -rf /etc/nginx/nginx.conf
create layer3 container from layer3 image
layer4 image=layer3+RUN rm -rf /etc/nginx/conf.d/default.conf
FROM nginx
RUN rm -rf /usr/share/nginx/html/index.html
RUN rm -rf /etc/nginx/nginx.conf
RUN rm -rf /etc/nginx/conf.d/default.conf
USER nginx
FROM nginx
RUN rm -rf /usr/share/nginx/html/index.html