Nico Huber has uploaded this change for review.
manibuilder/anita: Make disk and memory sizes configurable
Change-Id: I95e428a19b4c2042430d3147845397adb1c37e9b
Signed-off-by: Nico Huber <nico.h@gmx.de>
---
M util/manibuilder/Dockerfile.anita
M util/manibuilder/Makefile
2 files changed, 10 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/79/51479/1
diff --git a/util/manibuilder/Dockerfile.anita b/util/manibuilder/Dockerfile.anita
index c31f541..5fba6cc 100644
--- a/util/manibuilder/Dockerfile.anita
+++ b/util/manibuilder/Dockerfile.anita
@@ -2,6 +2,8 @@
ARG PKG_PATH=http://cdn.netbsd.org/pub/pkgsrc/packages/NetBSD/amd64/7.1/All
ARG INST_IMG=http://ftp.de.netbsd.org/pub/NetBSD/NetBSD-7.1/amd64/
+ARG DISK_SIZE=1G
+ARG MEM_SIZE=128M
ARG EXTRA_PKG=""
RUN \
@@ -18,7 +20,8 @@
USER mani
RUN cd && mkdir .ccache && chown mani:mani .ccache && \
anita --sets kern-GENERIC,modules,base,etc,comp \
- --disk-size 1024M --memory-size=128M install ${INST_IMG} && \
+ --disk-size ${DISK_SIZE} --memory-size=${MEM_SIZE} \
+ install ${INST_IMG} && \
rm -rf work-*/download
RUN cd && anita --persist --run \
diff --git a/util/manibuilder/Makefile b/util/manibuilder/Makefile
index 6baa4df..839fcbf 100644
--- a/util/manibuilder/Makefile
+++ b/util/manibuilder/Makefile
@@ -21,10 +21,15 @@
anita\:i386-build: PKGSRC_PATH=pub/pkgsrc/packages/NetBSD/i386/7.1/All
anita\:i386-build: NETBSD_IMAGE=pub/NetBSD/NetBSD-7.1/i386/
+$(addsuffix -build,$(ANITA_TAGS)): QEMU_DISK_SIZE=1G
+$(addsuffix -build,$(ANITA_TAGS)): QEMU_MEM_SIZE=128M
+
$(addsuffix -build,$(ANITA_TAGS)): %-build: Dockerfile.anita anita-wrapper.sh
$(QUIET_SETUP)docker build . -f $< -t mani/$* \
--build-arg PKG_PATH=$(PKGSRC_MIRROR)$(PKGSRC_PATH) \
- --build-arg INST_IMG=$(NETBSD_MIRROR)$(NETBSD_IMAGE)
+ --build-arg INST_IMG=$(NETBSD_MIRROR)$(NETBSD_IMAGE) \
+ --build-arg DISK_SIZE=$(QEMU_DISK_SIZE) \
+ --build-arg MEM_SIZE=$(QEMU_MEM_SIZE)
define build_template
Dockerfile.$(call ident,$(1)): Dockerfile.$(call stem,$(1)) mani-wrapper.sh
To view, visit change 51479. To unsubscribe, or for help writing mail filters, visit settings.