Dockerfile: include spdx-licenses-list

This is for linting license field on Travis.

One can also customize image as simple as
docker build "--build-arg=ADDINS=moreutils jq"
This commit is contained in:
Piotr Wójcik 2019-06-13 22:46:13 +02:00 committed by Michael Aldridge
parent 8ad31657b7
commit 163a923529
2 changed files with 3 additions and 2 deletions

View File

@ -17,6 +17,7 @@ FROM scratch as stage1
ARG REPOSITORY=https://alpha.de.repo.voidlinux.org ARG REPOSITORY=https://alpha.de.repo.voidlinux.org
ARG ARCH=x86_64 ARG ARCH=x86_64
ARG BASEPKG=base-minimal ARG BASEPKG=base-minimal
ARG ADDINS=
COPY --from=stage0 /target / COPY --from=stage0 /target /
COPY keys/* /target/var/db/xbps/keys/ COPY keys/* /target/var/db/xbps/keys/
RUN xbps-reconfigure -a && \ RUN xbps-reconfigure -a && \
@ -25,7 +26,7 @@ RUN xbps-reconfigure -a && \
--repository=${REPOSITORY}/current \ --repository=${REPOSITORY}/current \
--repository=${REPOSITORY}/current/musl \ --repository=${REPOSITORY}/current/musl \
-r /target \ -r /target \
${BASEPKG} ${BASEPKG} ${ADDINS}
# 3) configure and clean up the final image # 3) configure and clean up the final image
FROM scratch FROM scratch

View File

@ -99,6 +99,6 @@ masterdir-all-print:
masterdir-all: $(ALL_MASTERDIRS) masterdir-all: $(ALL_MASTERDIRS)
masterdir-%: masterdir-%:
$(SUDO) docker build --build-arg REPOSITORY=$(XBPS_REPOSITORY) --build-arg ARCH=$* -t voidlinux/masterdir-$*:$(DATECODE) . $(SUDO) docker build --build-arg REPOSITORY=$(XBPS_REPOSITORY) --build-arg ARCH=$* --build-arg ADDINS=spdx-licenses-list -t voidlinux/masterdir-$*:$(DATECODE) .
.PHONY: clean dist rootfs-all-print rootfs-all platformfs-all-print platformfs-all pxe-all-print pxe-all masterdir-all-print masterdir-all masterdir-push-all .PHONY: clean dist rootfs-all-print rootfs-all platformfs-all-print platformfs-all pxe-all-print pxe-all masterdir-all-print masterdir-all masterdir-push-all