Commit 0ff6c912 authored by Natanael Copa's avatar Natanael Copa

alpine.mk: vserver template target

parent 5994aa62
......@@ -10,6 +10,8 @@ DESTDIR ?= $(shell pwd)/isotmp
APORTS_DIR ?= $(HOME)/aports
REPOS ?= core extra
SUDO = sudo
# this might need to change...
APKDIRS ?= $(REPOS_DIR)/*/
......@@ -199,6 +201,21 @@ $(INITFS): $(INITFS_DIRSTAMP) $(INITFS_DIR)/init $(INITFS_DIR)/sbin/bootchartd $
@mkdir -p $(dir $(INITFS))
@(cd $(INITFS_DIR) && find . | cpio -o -H newc | gzip -9) > $(INITFS)
#
# Vserver template rules
#
VSTEMPLATE := $(ISO_DIR)/vs-template.tar.bz2
VSTEMPLATE_DIR := $(DESTDIR)/vs-template
vstemplate: $(VSTEMPLATE)
@echo "==> vstemplate: built $(VSTEMPLATE)"
$(VSTEMPLATE):
@$(SUDO) rm -rf "$(VSTEMPLATE_DIR)"
@$(SUDO) mkdir -p "$(VSTEMPLATE_DIR)"
@$(SUDO) apk add --initdb --root $(VSTEMPLATE_DIR) alpine-baselayout
@cd $(VSTEMPLATE_DIR) && $(SUDO) tar -jcf $@ *
#
# ISO rules
#
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment