Run Real nginx with Docker (port mapping & restart policies)

Опубликовано: 23 Май 2026
на канале: Dargslan
24
0

Lesson 03 of the Docker Beginners Guide.

Today we leave hello-world behind. We run nginx properly: port-mapped, named,
detached, restart-aware, with a volume mount for the served HTML. The
production-shape one-liner that becomes muscle memory.

⏱ Chapters
00:00 Why hello-world isn't enough
01:00 The full one-liner explained
02:00 Port mapping: -p 8080:80 (host:container)
03:00 Restart policies: no, on-failure, always, unless-stopped
04:00 Volume mounts (the preview)
04:30 docker inspect with Go templates
05:00 Common port-mapping pitfalls
06:00 Continue to Lesson 04

📺 Previous: Lesson 02 — Images
📺 Next: Lesson 04 — Volumes

#Docker #nginx #SelfHosted