summaryrefslogtreecommitdiffstats
path: root/F18-trimslice.ks
diff options
context:
space:
mode:
Diffstat (limited to 'F18-trimslice.ks')
-rw-r--r--F18-trimslice.ks101
1 files changed, 101 insertions, 0 deletions
diff --git a/F18-trimslice.ks b/F18-trimslice.ks
new file mode 100644
index 0000000..06c1487
--- /dev/null
+++ b/F18-trimslice.ks
@@ -0,0 +1,101 @@
+# Build a minimal Fedora ARM (Tegra) Trim Slice image using livemedia-creator
+
+lang en_US.UTF-8
+keyboard us
+timezone --utc US/Eastern
+auth --useshadow --enablemd5
+selinux --enforcing
+firewall --enabled --service=mdns,ssh
+network --bootproto=dhcp --device=eth0 --onboot=on --activate --hostname=trimslice-f18-v7hl
+services --enabled=NetworkManager,sshd,ntpd --disabled=network
+
+# Only use this with Anaconda for serial console installs, not with livemedia-creator.
+#cmdline
+skipx
+
+# Set a default root password for Fedora
+rootpw --plaintext fedora
+
+# Repositories
+# apparently we must use 'url' for the install repo for livemedia-creator
+url --url="http://archive.kernel.org/fedora-secondary/development/18/armhfp/os/"
+
+#
+# Define how large you want your rootfs to be
+#
+# NOTE: /boot and swap MUST use --asprimary to ensure '/' is
+# the last partition in order for rootfs-resize to work.
+#
+bootloader --location=none
+zerombr
+clearpart --all
+part /boot --size 200 --fstype ext3 --label=boot
+part swap --size 500 --asprimary --label=swap
+part / --size 2000 --fstype ext4 --label=rootfs
+
+#
+# Add all the packages after the base packages
+#
+%packages --nobase
+@standard
+
+# apparently none of the groups sets the clock.
+ntp
+ntpdate
+
+# and ifconfig would be nice.
+net-tools
+
+# we'll want to resize the rootfs on first boot
+rootfs-resize
+
+# get the uboot tools
+uboot-tools
+
+%end
+
+
+# more configuration
+%post --erroronfail
+
+
+# Install U-Boot boot.scr
+pushd /boot
+
+# get the root device from fstab, typically UUID=<string>
+ROOTDEV=`grep -w / /etc/fstab | cut -d ' ' -f1`
+
+# setup boot.scr
+cat <<EOL > boot.cmd.mmc
+setenv bootargs mem=384M@0M mem=512M@512M nvmem=128M@384M vmalloc=248M video=tegrafb console=ttyS0,115200n8 root=$ROOTDEV ro rootwait
+ext2load mmc 0:1 4880000 uInitrd
+ext2load mmc 0:1 4080000 uImage
+bootm 4080000 4880000
+EOL
+
+sed -e 's/mmc/usb/g' boot.cmd.mmc > boot.cmd.usb
+
+/usr/bin/mkimage -A arm -O linux -T script -C none -a 0 -e 0 -n "Trim Slice F18" -d boot.cmd.mmc boot.scr.mmc
+/usr/bin/mkimage -A arm -O linux -T script -C none -a 0 -e 0 -n "Trim Slice F18" -d boot.cmd.usb boot.scr.usb
+
+cp -p boot.scr.mmc boot.scr
+
+popd
+
+
+# datestamp this release
+date +F18-%Y%m%d-beta > /etc/RELEASE
+
+# force resize of the rootfs
+touch /.rootfs-repartition
+
+# force SELinux relabel of the rootfs
+#touch /.autorelabel
+
+# try Brendan's tip for workaround.
+setfiles -v -F -e /proc -e /sys -e /dev \
+ /etc/selinux/targeted/contexts/files/file_contexts /
+
+
+%end
+