Bygga image från Dockerfile: Revision history

Jump to navigation Jump to search

Diff selection: Mark the radio buttons of the revisions to compare and hit enter or the button at the bottom.
Legend: (cur) = difference with latest revision, (prev) = difference with preceding revision, m = minor edit.

11 May 2026

28 January 2022

20 January 2022

  • curprev 10:4010:40, 20 January 2022 Linuxwiki>Wikiadmin m 463 bytes 0 Wikiadmin flyttade sidan Dockerfile basic till Bygga image från Dockerfile utan att lämna en omdirigering
  • curprev 10:3910:39, 20 January 2022 Linuxwiki>Wikiadmin 463 bytes +463 Skapade sidan med '== Enkelt om att bygga sin egen image från Dockerfile == Skapa en '''Dockerfile''' '''FROM debian:stretch-slim''' <- Exempel Bygg din image '''docker build -t stretch:v1 .''' <- Glöm inte . (punkten) Nu har vi byggt en image baserad på stretch:v1. Skapa en container '''docker run -itd --name slim1 stretch:v1''' <- Här ges namnet slim1 men annat kan väljas. För att ansluta till docker med bash '''docker exec -it slim1 bash''' Category:docker'