local-server/Dockerfile

27 lines
735 B
Docker
Raw Normal View History

2018-11-13 03:44:15 +00:00
# ------------------------------------------------------------------------
2019-01-21 22:44:11 +00:00
from golang:1.11.4 as build
2018-11-13 03:44:15 +00:00
2018-06-19 06:49:34 +00:00
env pkg novit.nc/direktil/local-server
2018-11-13 03:44:15 +00:00
copy vendor /go/src/${pkg}/vendor
2019-01-21 22:44:11 +00:00
copy pkg /go/src/${pkg}/pkg
2018-11-13 03:44:15 +00:00
copy cmd /go/src/${pkg}/cmd
2018-06-19 06:49:34 +00:00
workdir /go/src/${pkg}
2018-12-10 10:59:24 +00:00
run go test ./... \
2018-11-13 03:44:15 +00:00
&& go install ./cmd/...
2018-06-19 06:49:34 +00:00
2018-11-13 03:44:15 +00:00
# ------------------------------------------------------------------------
from debian:stretch
entrypoint ["/bin/dkl-local-server"]
2018-06-19 06:49:34 +00:00
run apt-get update \
2018-11-13 03:44:15 +00:00
&& apt-get install -y genisoimage gdisk dosfstools util-linux udev \
&& apt-get clean
run yes |apt-get install -y grub2 grub-pc-bin grub-efi-amd64-bin \
2018-06-19 06:49:34 +00:00
&& apt-get clean
2018-11-13 03:44:15 +00:00
add scripts /scripts
add assets /assets
add efi-shim/ /shim
copy --from=build /go/bin/ /bin/