Answer the question
In order to leave comments, you need to log in
How to do docker build inside Dockerfile?
There is a Dockerfile (important part in bold):
FROM docker:dind
RUN apk add --no-cache go
RUN go version
WORKDIR /app
COPY go.mod ./
ADD index.html /app/index.html
ADD dock /app/dock
ADD flag.txt /app/flag. txt
#COPY go.sum ./
RUN go mod download
COPY *.go ./
RUN go build -o /main
EXPOSE 8080
RUN mv dock Dockerfile
RUN docker build -t interesting_container .
RUN docker run -t -d interesting_container
CMD [ "/main" ]
Cannot connect to the Docker daemon at unix:///var/run/docker.sock . Is the docker daemon running?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question