我正在尝试构建docker,但不断抛出错误
ERROR: Service 'telegraf' failed to build: COPY failed: stat /var/lib/docker/tmp/docker-builder163419820/telegraf-telemetry.zip: no such file or directory
这是Dockerfile:
FROM golang:alpine
RUN apk add curl git make unzip
RUN curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
RUN pwd
RUN ls /tmp/
COPY telegraf.zip /tmp/
RUN unzip /tmp/telegraf.zip
RUN ls -la /tmp/
我想将zip复制到/ tmp /并解压缩并复制到go
文件夹
答案 0 :(得分:0)
i解压缩文件,然后使用COPY将内容复制到目录中。 谢谢