docker build

Ja L·2023년 3월 16일
0

docker

목록 보기
1/4

docker image build -t 이미지명:[태그명] Dockerfile의 경로

  1. -t 옵션은 이미지명과 태그명을 붙이는 것 실제 사용에서 거의 필수

  2. 도커파일 경로에서 "."은 현재 작업 디렉터리

  3. -f 옵션은 기본인 Dockerfile 대신에 다른 파일 명을 사용할 경우 사용

$ docker image build -f Dockerfile-test -t exmaple/echo:latest

  1. --pull 옵션은 매번 베이스 이미지를 강제로 새로 받아옴

$ docker image build --pull=true -t exmaple/echo:latest

profile
DB Engineer

0개의 댓글