-
Notifications
You must be signed in to change notification settings - Fork 12
Lesson 4 br #22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Lesson 4 br #22
Changes from all commits
7d90ced
64ac560
2d871d3
130f1b1
297d380
3214bc6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,11 +1,11 @@ | ||
|
|
||
| - Image Size: | ||
| - Container Name: | ||
| - Container ID: | ||
| - Exposed port: | ||
| - Postgres version: | ||
| - Data Volume (aka PGDATA): | ||
| - default entrypoint: | ||
| - default command: | ||
| - baseline consumption : CPU ___% MEM ___MB | ||
| - Image Size: 377MB | ||
| - Container Name: some-postgres | ||
| - Container ID: 021d486917aa | ||
| - Exposed port: 5432/tcp | ||
| - Postgres version: 15.0-1.pgdg110+1 | ||
| - Data Volume (aka PGDATA): /var/lib/postgresql/data | ||
| - default entrypoint: docker-entrypoint.sh | ||
| - default command: postgres | ||
| - baseline consumption : CPU 0.00% MEM 31.37MiB | ||
| - OS: Distro Version Codename (Ubuntu 22.04 jammy) |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1,5 @@ | ||
| docker pull | ||
| docker run --name some-postgres -e POSTGRES_PASSWORD=mysecretpassword -d postgres | ||
| docker ps -h | ||
| docker inspect postgress | ||
CrAbelleira marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| docker images postgres | ||
| docker stats some-postgress | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,2 +1,5 @@ | ||
| REPOSITORY TAG IMAGE ID CREATED SIZE | ||
| nginx | ||
| REPOSITORY TAG IMAGE ID CREATED SIZE | ||
| nginx 1.22.1-perl df1998569adb 10 days ago 188MB | ||
| nginx 1.22.1 0ccb2559380c 10 days ago 142MB | ||
| nginx 1.22.1-alpine-perl 98f7c1f8a3fa 2 weeks ago 58.6MB | ||
| nginx 1.22.1-alpine ec84f916d1ec 2 weeks ago 23.6MB |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1,4 @@ | ||
| docker pull | ||
| docker pull nginx:1.22.1-perl | ||
| docker pull nginx:1.22.1-alpine-perl | ||
| docker pull nginx:1.22.1-alpine | ||
| docker pull nginx:1.22.1 |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| docker run --name some-nginx -p 8011:80 -d nginx:1.22.1 | ||
| docker exec -ti some-nginx /bin/bash | ||
| cat /etc/nginx/nginx.conf | ||
| exit | ||
| docker stop some-nginx | ||
| docker rm some-nginx | ||
| docker run --name some-nginx -p 8888:80 -d -v /home/cursodocker/dockerexercises/docker_exercises/lesson_4/ex1.conf:/etc/nginx/nginx.conf -v /home/cursodocker/dockerexercises/docker_exercises/lesson_4/src/ex1_web.html:/var/www/index.html nginx:1.22.1 | ||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. recorda que podes user $(pwd) para substituír o teu directorio actual. Na maioría dos casos unha ruta relativa vai funcionar. Eu uso
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. modificaches o ex1.conf? o que hai está sen completar |
||
| docker logs my-nginx | ||
| docker stop some-nginx | ||
| docker inspect some-nginx | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,19 +1,115 @@ | ||
| ### Part 1 | ||
| Welcome to nginx! | ||
| If you see this page, the nginx web server is successfully installed and working. Further configuration is required. | ||
|
|
||
| For online documentation and support please refer to nginx.org. | ||
| Commercial support is available at nginx.com. | ||
|
|
||
| Thank you for using nginx. | ||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
| ### Part 2 | ||
|
|
||
| ### Part 3 logs | ||
| Pese a que los volumenes parecen bien montados y los archivos efectivamente están donde deberían, no me muestra la página correcta ni a tiros. | ||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. revisa o ex1.conf. Tes que modificalo usando o nginx.conf de dentro máis a sección "server" de lesson_4/src/nginx.conf |
||
| Tampoco me deja ver los logs de nginx desde dentro de la maquina | ||
CrAbelleira marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| ### Part 3 logs | ||
| /docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration | ||
| /docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/ | ||
| /docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh | ||
| 10-listen-on-ipv6-by-default.sh: info: Getting the checksum of /etc/nginx/conf.d/default.conf | ||
| 10-listen-on-ipv6-by-default.sh: info: Enabled listen on IPv6 in /etc/nginx/conf.d/default.conf | ||
| /docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh | ||
| /docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh | ||
| /docker-entrypoint.sh: Configuration complete; ready for start up | ||
| 2022/11/10 19:29:05 [notice] 1#1: using the "epoll" event method | ||
| 2022/11/10 19:29:05 [notice] 1#1: nginx/1.22.1 | ||
| 2022/11/10 19:29:05 [notice] 1#1: built by gcc 10.2.1 20210110 (Debian 10.2.1-6) | ||
| 2022/11/10 19:29:05 [notice] 1#1: OS: Linux 5.10.102.1-microsoft-standard-WSL2 | ||
| 2022/11/10 19:29:05 [notice] 1#1: getrlimit(RLIMIT_NOFILE): 1048576:1048576 | ||
| 2022/11/10 19:29:05 [notice] 1#1: start worker processes | ||
| 2022/11/10 19:29:05 [notice] 1#1: start worker process 29 | ||
| 2022/11/10 19:29:05 [notice] 1#1: start worker process 30 | ||
| 2022/11/10 19:29:05 [notice] 1#1: start worker process 31 | ||
| 2022/11/10 19:29:05 [notice] 1#1: start worker process 32 | ||
| 2022/11/10 19:29:05 [notice] 1#1: start worker process 33 | ||
| 2022/11/10 19:29:05 [notice] 1#1: start worker process 34 | ||
| 2022/11/10 19:29:05 [notice] 1#1: start worker process 35 | ||
| 2022/11/10 19:29:05 [notice] 1#1: start worker process 36 | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 1 (SIGHUP) received from 50, reconfiguring | ||
| 2022/11/10 19:31:47 [notice] 1#1: reconfiguring | ||
| 2022/11/10 19:31:47 [notice] 1#1: using the "epoll" event method | ||
| 2022/11/10 19:31:47 [notice] 1#1: start worker processes | ||
| 2022/11/10 19:31:47 [notice] 1#1: start worker process 53 | ||
| 2022/11/10 19:31:47 [notice] 1#1: start worker process 54 | ||
| 2022/11/10 19:31:47 [notice] 1#1: start worker process 56 | ||
| 2022/11/10 19:31:47 [notice] 1#1: start worker process 57 | ||
| 2022/11/10 19:31:47 [notice] 1#1: start worker process 59 | ||
| 2022/11/10 19:31:47 [notice] 1#1: start worker process 60 | ||
| 2022/11/10 19:31:47 [notice] 1#1: start worker process 61 | ||
| 2022/11/10 19:31:47 [notice] 1#1: start worker process 63 | ||
| 2022/11/10 19:31:47 [notice] 29#29: gracefully shutting down | ||
| 2022/11/10 19:31:47 [notice] 30#30: gracefully shutting down | ||
| 2022/11/10 19:31:47 [notice] 32#32: gracefully shutting down | ||
| 2022/11/10 19:31:47 [notice] 31#31: gracefully shutting down | ||
| 2022/11/10 19:31:47 [notice] 33#33: gracefully shutting down | ||
| 2022/11/10 19:31:47 [notice] 32#32: exiting | ||
| 2022/11/10 19:31:47 [notice] 29#29: exiting | ||
| 2022/11/10 19:31:47 [notice] 30#30: exiting | ||
| 2022/11/10 19:31:47 [notice] 34#34: gracefully shutting down | ||
| 2022/11/10 19:31:47 [notice] 36#36: gracefully shutting down | ||
| 2022/11/10 19:31:47 [notice] 33#33: exiting | ||
| 2022/11/10 19:31:47 [notice] 31#31: exiting | ||
| 2022/11/10 19:31:47 [notice] 34#34: exiting | ||
| 2022/11/10 19:31:47 [notice] 36#36: exiting | ||
| 2022/11/10 19:31:47 [notice] 33#33: exit | ||
| 2022/11/10 19:31:47 [notice] 29#29: exit | ||
| 2022/11/10 19:31:47 [notice] 32#32: exit | ||
| 2022/11/10 19:31:47 [notice] 30#30: exit | ||
| 2022/11/10 19:31:47 [notice] 31#31: exit | ||
| 2022/11/10 19:31:47 [notice] 34#34: exit | ||
| 2022/11/10 19:31:47 [notice] 36#36: exit | ||
| 2022/11/10 19:31:47 [notice] 35#35: gracefully shutting down | ||
| 2022/11/10 19:31:47 [notice] 35#35: exiting | ||
| 2022/11/10 19:31:47 [notice] 35#35: exit | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 17 (SIGCHLD) received from 31 | ||
| 2022/11/10 19:31:47 [notice] 1#1: worker process 31 exited with code 0 | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 29 (SIGIO) received | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 17 (SIGCHLD) received from 36 | ||
| 2022/11/10 19:31:47 [notice] 1#1: worker process 29 exited with code 0 | ||
| 2022/11/10 19:31:47 [notice] 1#1: worker process 34 exited with code 0 | ||
| 2022/11/10 19:31:47 [notice] 1#1: worker process 36 exited with code 0 | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 29 (SIGIO) received | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 17 (SIGCHLD) received from 32 | ||
| 2022/11/10 19:31:47 [notice] 1#1: worker process 32 exited with code 0 | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 29 (SIGIO) received | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 17 (SIGCHLD) received from 30 | ||
| 2022/11/10 19:31:47 [notice] 1#1: worker process 30 exited with code 0 | ||
| 2022/11/10 19:31:47 [notice] 1#1: worker process 33 exited with code 0 | ||
| 2022/11/10 19:31:47 [notice] 1#1: worker process 35 exited with code 0 | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 29 (SIGIO) received | ||
| 2022/11/10 19:31:47 [notice] 1#1: signal 17 (SIGCHLD) received from 35 | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:52 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:53 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:53 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:54 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:54 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:54 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:55 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:55 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:55 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:56 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:56 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
| 172.17.0.1 - - [10/Nov/2022:19:31:56 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Edg/107.0.1418.26" "-" | ||
|
|
||
| ### Part 4 status | ||
|
|
||
| Name | ||
| Status | ||
| Exit code | ||
| Name /some-nginx | ||
| Status exited | ||
| Exit code 0 | ||
|
|
||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.