mirror of
https://github.com/bensuperpc/dockcross.git
synced 2025-01-03 13:44:27 +01:00
Merge pull request #81 from jcfr/avoid-rebuild-of-base
base: Optimize image build adding only image and vcs_url metatdata
This commit is contained in:
commit
593d6a5c07
@ -34,12 +34,10 @@ RUN apt-get update && apt-get -y install \
|
|||||||
#include "common.docker"
|
#include "common.docker"
|
||||||
|
|
||||||
# Build-time metadata as defined at http://label-schema.org
|
# Build-time metadata as defined at http://label-schema.org
|
||||||
ARG BUILD_DATE
|
# Note: To avoid systematic rebuild of dependent images, only
|
||||||
|
# name and vcs-url are included.
|
||||||
ARG IMAGE
|
ARG IMAGE
|
||||||
ARG VCS_REF
|
|
||||||
ARG VCS_URL
|
ARG VCS_URL
|
||||||
LABEL org.label-schema.build-date=$BUILD_DATE \
|
LABEL org.label-schema.name=$IMAGE \
|
||||||
org.label-schema.name=$IMAGE \
|
|
||||||
org.label-schema.vcs-ref=$VCS_REF \
|
|
||||||
org.label-schema.vcs-url=$VCS_URL \
|
org.label-schema.vcs-url=$VCS_URL \
|
||||||
org.label-schema.schema-version="1.0"
|
org.label-schema.schema-version="1.0"
|
||||||
|
2
Makefile
2
Makefile
@ -98,9 +98,7 @@ Dockerfile: Dockerfile.in common.docker
|
|||||||
base: Dockerfile imagefiles/
|
base: Dockerfile imagefiles/
|
||||||
$(DOCKER) build -t $(ORG)/base \
|
$(DOCKER) build -t $(ORG)/base \
|
||||||
--build-arg IMAGE=$(ORG)/base \
|
--build-arg IMAGE=$(ORG)/base \
|
||||||
--build-arg VCS_REF=`git rev-parse --short HEAD` \
|
|
||||||
--build-arg VCS_URL=`git config --get remote.origin.url` \
|
--build-arg VCS_URL=`git config --get remote.origin.url` \
|
||||||
--build-arg BUILD_DATE=`date -u +"%Y-%m-%dT%H:%M:%SZ"` \
|
|
||||||
.
|
.
|
||||||
|
|
||||||
base.test: base
|
base.test: base
|
||||||
|
Loading…
Reference in New Issue
Block a user