integrate reHDD
This commit is contained in:
parent
a6306ab0cb
commit
d5eaecf672
6
.gitmodules
vendored
Normal file
6
.gitmodules
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
[submodule "root/root/reHDD"]
|
||||
path = root/root/reHDD
|
||||
url = gitea@git.mosad.xyz:localhorst/reHDD.git
|
||||
[submodule "root/root/reHDDPrinter"]
|
||||
path = root/root/reHDDPrinter
|
||||
url = gitea@git.mosad.xyz:localhorst/reHDDPrinter.git
|
@ -6,6 +6,9 @@ Scripts and tools to create a bootable image with reHDD based on openSuse.
|
||||
|
||||
The scripts are used to run within a openSuse-based machine as host.
|
||||
|
||||
git submodule init
|
||||
git submodule update
|
||||
|
||||
## Build Image
|
||||
|
||||
`sudo bash ./create_bootable.sh`
|
||||
|
@ -58,6 +58,15 @@
|
||||
<package name="htop"/>
|
||||
<package name="usbutils"/>
|
||||
<package name="pciutils"/>
|
||||
<package name="ncurses-devel"/>
|
||||
<package name="ncurses5-devel"/>
|
||||
<package name="git"/>
|
||||
<package name="make"/>
|
||||
<package name="gcc-c++"/>
|
||||
<package name="hwinfo"/>
|
||||
<package name="smartmontools"/>
|
||||
<package name="curl"/>
|
||||
<package name="nano"/>
|
||||
</packages>
|
||||
<packages type="bootstrap">
|
||||
<package name="gawk"/>
|
||||
|
@ -13,6 +13,22 @@ printf "\nCleanup\n"
|
||||
rm -rf reHDD-Bootable.iso
|
||||
rm -rf out/
|
||||
|
||||
### Preconditions ###
|
||||
printf "\nPreconditions\n"
|
||||
current_dir=$(pwd)
|
||||
cd ./root/root/reHDD/
|
||||
git stash
|
||||
git checkout master
|
||||
git submodule init
|
||||
git submodule update
|
||||
make release
|
||||
cd $current_dir
|
||||
|
||||
cd ./root/root/reHDDPrinter/
|
||||
git stash
|
||||
git checkout main
|
||||
cd $current_dir
|
||||
|
||||
### Build ###
|
||||
printf "\nBuild\n"
|
||||
START=$(date +%s.%N)
|
||||
|
@ -1,4 +0,0 @@
|
||||
BOOTPROTO='dhcp'
|
||||
MTU=''
|
||||
REMOTE_IPADDR=''
|
||||
STARTMODE='onboot'
|
@ -1 +0,0 @@
|
||||
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="?*", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="?*", NAME="lan0"
|
1
root/root/reHDD
Submodule
1
root/root/reHDD
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit 5d2094939b0257824b981d7a5dfbd5d4d859a0cb
|
1
root/root/reHDDPrinter
Submodule
1
root/root/reHDDPrinter
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit 63ba1e8d1df2ce7ef3178ce62a9286824be0fc60
|
@ -1,11 +0,0 @@
|
||||
[Unit]
|
||||
Description=Rebuild dracut initrd for this host
|
||||
ConditionPathExists=/.kiwi_dracut_hostonly.trigger
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/bin/bash -c 'dracut -f'
|
||||
ExecStartPost=/bin/bash -c 'rm -f /.kiwi_dracut_hostonly.trigger'
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
@ -0,0 +1,17 @@
|
||||
[Unit]
|
||||
Description=reHDD on tty1
|
||||
|
||||
[Service]
|
||||
WorkingDirectory=/root/reHDD/
|
||||
ExecStart=
|
||||
ExecStart=-/root/reHDD/reHDD
|
||||
StandardInput=tty
|
||||
StandardOutput=tty
|
||||
Restart=always
|
||||
RestartSec=1
|
||||
UtmpIdentifier=tty1
|
||||
TTYPath=/dev/tty1
|
||||
TTYReset=yes
|
||||
TTYVHangup=yes
|
||||
TTYVTDisallocate=yes
|
||||
SendSIGHUP=yes
|
@ -0,0 +1,17 @@
|
||||
[Unit]
|
||||
Description=dmesg on tty2
|
||||
|
||||
[Service]
|
||||
WorkingDirectory=/usr/bin/
|
||||
ExecStart=
|
||||
ExecStart=-/usr/bin/dmesg -wHT
|
||||
StandardInput=tty
|
||||
StandardOutput=tty
|
||||
Restart=always
|
||||
RestartSec=1
|
||||
UtmpIdentifier=tty2
|
||||
TTYPath=/dev/tty2
|
||||
TTYReset=yes
|
||||
TTYVHangup=yes
|
||||
TTYVTDisallocate=yes
|
||||
SendSIGHUP=yes
|
@ -0,0 +1,17 @@
|
||||
[Unit]
|
||||
Description=htop on tty3
|
||||
|
||||
[Service]
|
||||
WorkingDirectory=/usr/bin/
|
||||
ExecStart=
|
||||
ExecStart=-/usr/bin/htop
|
||||
StandardInput=tty
|
||||
StandardOutput=tty
|
||||
Restart=always
|
||||
RestartSec=1
|
||||
UtmpIdentifier=tty3
|
||||
TTYPath=/dev/tty3
|
||||
TTYReset=yes
|
||||
TTYVHangup=yes
|
||||
TTYVTDisallocate=yes
|
||||
SendSIGHUP=yes
|
@ -1,11 +0,0 @@
|
||||
[Unit]
|
||||
Description=Rebuild grub config from distro toolkit
|
||||
ConditionPathExists=/.kiwi_grub_config.trigger
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/bin/bash -c 'grub2-mkconfig -o /boot/grub2/grub.cfg'
|
||||
ExecStartPost=/bin/bash -c 'rm -f /.kiwi_grub_config.trigger'
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
18
root/usr/lib/systemd/system/reHDDLogUploader.service
Normal file
18
root/usr/lib/systemd/system/reHDDLogUploader.service
Normal file
@ -0,0 +1,18 @@
|
||||
[Unit]
|
||||
Description=reHDD log uploader
|
||||
After=syslog.target
|
||||
After=network.target
|
||||
After=network-online.target
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
User=root
|
||||
Group=root
|
||||
RemainAfterExit=yes
|
||||
ExecStart=/usr/bin/bash /root/reHDD/scripts/reHDDLogUploader.bash
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
||||
|
11
root/usr/lib/systemd/system/reHDDLogUploader.timer
Normal file
11
root/usr/lib/systemd/system/reHDDLogUploader.timer
Normal file
@ -0,0 +1,11 @@
|
||||
[Unit]
|
||||
Description=reHDD log uploader timer
|
||||
|
||||
[Timer]
|
||||
OnActiveSec=30s
|
||||
OnBootSec=10min
|
||||
OnUnitActiveSec=12h
|
||||
|
||||
[Install]
|
||||
WantedBy=basic.target
|
||||
|
16
root/usr/lib/systemd/system/reHDDStartHelper.service
Normal file
16
root/usr/lib/systemd/system/reHDDStartHelper.service
Normal file
@ -0,0 +1,16 @@
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
||||
[Unit]
|
||||
Description=reHDD start helper
|
||||
After=syslog.target
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
User=root
|
||||
Group=root
|
||||
RemainAfterExit=yes
|
||||
ExecStart=/usr/bin/bash /root/reHDD/scripts/reHDDStartHelper.bash
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
Reference in New Issue
Block a user