Compare commits
6 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
a45a0d1448 | ||
|
7045698d74 | ||
|
dce041a6fe | ||
|
5f1c11eb55 | ||
|
cf6dacddf2 | ||
|
42d58ca543 |
2
.gitignore
vendored
2
.gitignore
vendored
@@ -1 +1 @@
|
|||||||
*.sh
|
void-mklive.sh
|
||||||
|
7
Makefile
7
Makefile
@@ -1,4 +1,4 @@
|
|||||||
VERSION = 0.9.5
|
VERSION = 0.9.6
|
||||||
SBINDIR ?= /usr/sbin
|
SBINDIR ?= /usr/sbin
|
||||||
DRACUTMODDIR ?= /usr/lib/dracut/modules.d/01vmklive
|
DRACUTMODDIR ?= /usr/lib/dracut/modules.d/01vmklive
|
||||||
|
|
||||||
@@ -9,10 +9,7 @@ install: all
|
|||||||
install -d $(DESTDIR)$(SBINDIR)
|
install -d $(DESTDIR)$(SBINDIR)
|
||||||
install -m755 mklive.sh $(DESTDIR)$(SBINDIR)/void-mklive
|
install -m755 mklive.sh $(DESTDIR)$(SBINDIR)/void-mklive
|
||||||
install -d $(DESTDIR)$(DRACUTMODDIR)
|
install -d $(DESTDIR)$(DRACUTMODDIR)
|
||||||
install -m755 dracut/dracut-module.sh \
|
install -m755 dracut/*.sh $(DESTDIR)$(DRACUTMODDIR)
|
||||||
$(DESTDIR)$(DRACUTMODDIR)/module-setup.sh
|
|
||||||
install -m755 dracut/dracut-vmklive-adduser.sh \
|
|
||||||
$(DESTDIR)$(DRACUTMODDIR)/vmklive-adduser.sh
|
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
-rm -f mklive.sh
|
-rm -f mklive.sh
|
||||||
|
9
README
9
README
@@ -4,20 +4,19 @@ This is a simple shell script to build a live image for the
|
|||||||
Void linux distribution. The images contain the void-installer package
|
Void linux distribution. The images contain the void-installer package
|
||||||
to be able to install Void linux to storage disks.
|
to be able to install Void linux to storage disks.
|
||||||
|
|
||||||
Usage: vmklive [options]
|
Usage: void-mklive [options]
|
||||||
|
|
||||||
Options:
|
Options:
|
||||||
-C file Path to configuration file (defaults to ~/.mklive.conf)
|
-C file Path to configuration file (defaults to ~/.mklive.conf)
|
||||||
-c (gzip|bzip2|xz) Compression type for the squashfs/initramfs image.
|
-c (gzip|bzip2|xz) Compression type for the squashfs/initramfs image.
|
||||||
-k version Kernel version to use.
|
-k version Kernel version to use.
|
||||||
-o outfile Output file name for the ISO image.
|
-o outfile Output file name for the ISO image.
|
||||||
-r rootdir Rootfs directory.
|
|
||||||
-s splash Splash image file for isolinux.
|
-s splash Splash image file for isolinux.
|
||||||
-v volname ISO Volume name.
|
-v volname ISO Volume name.
|
||||||
|
|
||||||
NOTE: If -k not specified it will use $(uname -r) by default.
|
* If -k not specified it will use $(uname -r) by default.
|
||||||
NOTE: the first time it is executed a configuration file will be created at ~/mklive.conf.
|
* The first time it is executed a config file will be created (~/mklive.conf).
|
||||||
NOTE: It's assumed that void-mklive is run in a Void Linux system.
|
* It's assumed that void-mklive is executed in a Void Linux system.
|
||||||
|
|
||||||
Take a look at the configuration file (~/mklive.conf) to tweak some
|
Take a look at the configuration file (~/mklive.conf) to tweak some
|
||||||
default parameters in the generated image.
|
default parameters in the generated image.
|
||||||
|
@@ -13,4 +13,5 @@ depends() {
|
|||||||
install() {
|
install() {
|
||||||
inst chmod
|
inst chmod
|
||||||
inst_hook pre-pivot 01 "$moddir/vmklive-adduser.sh"
|
inst_hook pre-pivot 01 "$moddir/vmklive-adduser.sh"
|
||||||
|
inst_hook pre-pivot 02 "$moddir/vmklive-conf.sh"
|
||||||
}
|
}
|
25
dracut/vmklive-conf.sh
Normal file
25
dracut/vmklive-conf.sh
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*-
|
||||||
|
# ex: ts=8 sw=4 sts=4 et filetype=sh
|
||||||
|
|
||||||
|
KEYMAP=$(getarg vconsole.keymap)
|
||||||
|
FONT=$(getarg vconsole.font)
|
||||||
|
FONT_MAP=$(getarg vconsole.font.map)
|
||||||
|
FONT_UNIMAP=$(getarg vconsole.font.unimap)
|
||||||
|
LOCALE=$(getarg locale.LANG)
|
||||||
|
|
||||||
|
if [ -n "$KEYMAP" ]; then
|
||||||
|
sed -i -e "s|^KEYMAP=.*|KEYMAP=$KEYMAP|g" ${NEWROOT}/etc/vconsole.conf
|
||||||
|
fi
|
||||||
|
if [ -n "$FONT" ]; then
|
||||||
|
sed -i -e "s|^FONT=.*|FONT=$FONT|g" ${NEWROOT}/etc/vconsole.conf
|
||||||
|
fi
|
||||||
|
if [ -n "$FONT_MAP" ]; then
|
||||||
|
sed -i -e "s|^FONT_MAP=.*|FONT_MAP=$FONT_MAP|g" ${NEWROOT}/etc/vconsole.conf
|
||||||
|
fi
|
||||||
|
if [ -n "$FONT_UNIMAP" ]; then
|
||||||
|
sed -i -e "s|^FONT_UNIMAP=.*|FONT_UNIMAP=$FONT_UNIMAP|g" ${NEWROOT}/etc/vconsole.conf
|
||||||
|
fi
|
||||||
|
if [ -n "$LOCALE" ]; then
|
||||||
|
sed -i -e "s|^LANG=.*|LANG=$LOCALE|g" ${NEWROOT}/etc/locale.conf
|
||||||
|
fi
|
Reference in New Issue
Block a user