]> git.ipfire.org Git - ipfire-2.x.git/blob - src/installer/dracut-module/module-setup.sh
Move installer to its own directory.
[ipfire-2.x.git] / src / installer / dracut-module / module-setup.sh
1 #!/bin/bash
2 # -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*-
3 # ex: ts=8 sw=4 sts=4 et filetype=sh
4
5 # called by dracut
6 check() {
7 return 255
8 }
9
10 # called by dracut
11 depends() {
12 echo base bash mdraid shutdown
13 return 0
14 }
15
16 # called by dracut
17 install() {
18 inst /etc/system-release
19 inst /usr/bin/installer
20 inst /usr/bin/downloadsource.sh
21 inst /usr/local/bin/iowrap
22
23 # Kernel drivers
24 instmods =drivers/hid
25
26 # Network drivers
27 instmods =drivers/net/ethernet =drivers/net/usb
28 instmods virtio_net hv_netvsc vmxnet3
29
30 # Filesystem support
31 inst_multiple parted mkswap mke2fs mkreiserfs mkfs.xfs
32 instmods ext4 iso9660 reiserfs vfat xfs
33
34 # Extraction
35 inst_multiple tar gzip lzma xz
36
37 # DHCP Client
38 inst dhcpcd
39 inst /var/ipfire/dhcpc/dhcpcd-run-hooks
40 inst /var/ipfire/dhcpc/dhcpcd.conf
41 for file in /var/ipfire/dhcpc/dhcpcd-hooks/*; do
42 inst "${file}"
43 done
44 inst "$moddir/70-dhcpcd.exe" "/var/ipfire/dhcpc/dhcpcd-hooks/70-dhcpcd.exe"
45
46 # Misc. tools
47 inst_multiple eject ping wget
48 inst_multiple -o fdisk cfdisk df ps top
49
50 # Hardware IDs
51 inst /usr/share/hwdata/pci.ids /usr/share/hwdata/usb.ids
52
53 # Locales
54 for locale in de en es fr nl pl ru tr; do
55 for file in $(find /usr/lib/locale/${locale}*); do
56 inst "${file}"
57 done
58 done
59
60 # Bash start files
61 inst_multiple /etc/profile /root/.bash_profile /etc/bashrc /root/.bashrc
62 inst_dir /etc/profile.d
63
64 inst_hook cmdline 99 "$moddir/fake-root.sh"
65 inst_hook pre-mount 99 "$moddir/run-installer.sh"
66
67 return 0
68 }