2024-01-11 21:27:58 +01:00
2024-01-11 14:25:28 +01:00
2024-01-11 21:27:58 +01:00
2024-01-11 14:25:28 +01:00
2024-01-11 14:25:28 +01:00

Uvod

  • Docker je platforma za development, delivery i izvršavanje aplikacija
  • Docker omogućava da se aplikacija izolira u repetativnoj okolini i odvoji od infrastrukture

Features of Docker:

  • Open-source platform
  • An Easy, lightweight, and consistent way of delivery of applications
  • Fast and efficient development life cycle
  • Segregation of duties
  • Service-oriented architecture
  • Security
  • Scalability
  • Reduction in size
  • Image management
  • Networking
  • Volume management

Struktura

  • Dockerfile
  • image
  • container registry
    • lokalni
    • dockerhub
    • AWS ECR
  • container

Dockerfile

  • base image
    • odabir najmanjeg funkcionalnog
    • debian prije ubuntua
    • debian-slim prije debiana
    • alpine
    • from scratch
  • env varijable

Docker image

  • single stage build
  • multistage build

Docker container

run:

docker run --name api-server-3000 --publish 3000:3000 --env CONTAINER_NAME="Awesome API server on port 3000" -d api-server
docker run --name api-server-3001 --publish 3001:3000 --env CONTAINER_NAME="Awesome API server on port 3001" -d api-server
docker run --name api-server-3002 --publish 3002:3000 --env CONTAINER_NAME="Awesome API server on port 3002" -d api-server
Description
No description provided
Readme 4.8 MiB
Languages
Dockerfile 34.9%
Makefile 26.7%
Python 25.5%
Shell 12.9%