mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-21 10:09:07 +00:00
Add a CI tag Makefile target
The CI will set `CI_TAG` to the tag name, which will be used for the uploaded images instead of the git commit ID. Signed-off-by: Justin Cormack <justin.cormack@docker.com>
This commit is contained in:
parent
ddafc8c871
commit
7fdb89d22f
12
Makefile
12
Makefile
@ -76,7 +76,12 @@ test: alpine/initrd-test.img kernel/x86_64/vmlinuz64
|
|||||||
tar cf - $^ | docker run --rm -i $(QEMU_IMAGE) 2>&1 | tee test.log
|
tar cf - $^ | docker run --rm -i $(QEMU_IMAGE) 2>&1 | tee test.log
|
||||||
$(call check_test_log, test.log)
|
$(call check_test_log, test.log)
|
||||||
|
|
||||||
|
ifeq ($(CI_TAG),)
|
||||||
TAG=$(shell git rev-parse HEAD)
|
TAG=$(shell git rev-parse HEAD)
|
||||||
|
else
|
||||||
|
TAG=$(CI_TAG)
|
||||||
|
endif
|
||||||
|
|
||||||
STATUS=$(shell git status -s)
|
STATUS=$(shell git status -s)
|
||||||
MOBYLINUX_TAG=alpine/mobylinux.tag
|
MOBYLINUX_TAG=alpine/mobylinux.tag
|
||||||
ifdef AUFS
|
ifdef AUFS
|
||||||
@ -85,6 +90,7 @@ endif
|
|||||||
ifdef LTS4.4
|
ifdef LTS4.4
|
||||||
AUFS_PREFIX=lts4.4-
|
AUFS_PREFIX=lts4.4-
|
||||||
endif
|
endif
|
||||||
|
|
||||||
MEDIA_IMAGE=mobylinux/media:$(MEDIA_PREFIX)$(AUFS_PREFIX)$(TAG)
|
MEDIA_IMAGE=mobylinux/media:$(MEDIA_PREFIX)$(AUFS_PREFIX)$(TAG)
|
||||||
INITRD_IMAGE=mobylinux/mobylinux:$(MEDIA_PREFIX)$(AUFS_PREFIX)$(TAG)
|
INITRD_IMAGE=mobylinux/mobylinux:$(MEDIA_PREFIX)$(AUFS_PREFIX)$(TAG)
|
||||||
KERNEL_IMAGE=mobylinux/kernel:$(MEDIA_PREFIX)$(AUFS_PREFIX)$(TAG)
|
KERNEL_IMAGE=mobylinux/kernel:$(MEDIA_PREFIX)$(AUFS_PREFIX)$(TAG)
|
||||||
@ -154,6 +160,12 @@ ci:
|
|||||||
$(MAKE) test
|
$(MAKE) test
|
||||||
$(MAKE) media
|
$(MAKE) media
|
||||||
|
|
||||||
|
ci-tag:
|
||||||
|
$(MAKE) clean
|
||||||
|
$(MAKE) all
|
||||||
|
$(MAKE) test
|
||||||
|
$(MAKE) media
|
||||||
|
|
||||||
ci-pr:
|
ci-pr:
|
||||||
$(MAKE) clean
|
$(MAKE) clean
|
||||||
$(MAKE) all
|
$(MAKE) all
|
||||||
|
Loading…
Reference in New Issue
Block a user