mirror of
https://github.com/blazblue547-afk/nova-os.git
synced 2026-12-02 14:54:17 -05:00
Rootfs: busybox-static 1.37.0, init system, shell configs
This commit is contained in:
1 parent
4e0f8b3b87
commit
d101fff92e
3 files changed
+27
-15
No files matched your search
@@ -2,3 +2,8 @@ build/
|
|||||||
*.img
|
*.img
|
||||||
*.tar.xz
|
*.tar.xz
|
||||||
*.tar.bz2
|
*.tar.bz2
|
||||||
|
rootfs/bin/
|
||||||
|
rootfs/sbin/
|
||||||
|
rootfs/lib/
|
||||||
|
rootfs/dev/
|
||||||
|
!rootfs/bin/.gitkeep
|
||||||
Regular → Executable
File mode changed.
+22
-15
@@ -1,9 +1,11 @@
|
|||||||
#!/bin/busybox sh
|
#!/bin/sh
|
||||||
#
|
#
|
||||||
# Nova OS - init
|
# Nova OS - init
|
||||||
# Linux 7.0.12-nova-os
|
# Linux 7.0.12-nova-os — "Burn bright, run light."
|
||||||
#
|
#
|
||||||
|
|
||||||
|
export PATH=/bin:/sbin:/usr/bin:/usr/sbin
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
echo " ╔══════════════════════════════════════╗"
|
echo " ╔══════════════════════════════════════╗"
|
||||||
echo " ║ N O V A O S ║"
|
echo " ║ N O V A O S ║"
|
||||||
@@ -13,29 +15,34 @@ echo " ╚═══════════════════════
|
|||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
# Mount essential filesystems
|
# Mount essential filesystems
|
||||||
mount -t proc proc /proc
|
mount -t proc none /proc
|
||||||
mount -t sysfs sysfs /sys
|
mount -t sysfs none /sys
|
||||||
mount -t devtmpfs devtmpfs /dev
|
mount -t devtmpfs none /dev
|
||||||
mount -t tmpfs tmpfs /tmp
|
mount -t tmpfs none /tmp
|
||||||
mount -t tmpfs tmpfs /run
|
mount -t tmpfs none /run
|
||||||
|
|
||||||
# Populate /dev
|
# Populate /dev
|
||||||
mdev -s
|
mdev -s
|
||||||
|
|
||||||
|
# Mount root writable
|
||||||
|
mount -o remount,rw /
|
||||||
|
|
||||||
# Set hostname
|
# Set hostname
|
||||||
hostname nova-os
|
hostname nova-os
|
||||||
|
|
||||||
echo ":: Mounting root filesystem..."
|
# Bring up loopback
|
||||||
mount -o remount,rw /
|
|
||||||
|
|
||||||
echo ":: Setting up loopback..."
|
|
||||||
ifconfig lo 127.0.0.1 up
|
ifconfig lo 127.0.0.1 up
|
||||||
|
|
||||||
echo ":: Starting syslogd..."
|
# Start logging
|
||||||
syslogd -t
|
syslogd
|
||||||
|
|
||||||
echo ":: Nova OS ready."
|
echo ":: Nova OS ready."
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
# Spawn shell on tty1
|
# Run the configured inittab if it exists
|
||||||
setsid cttyhack /bin/sh
|
if [ -f /etc/inittab ]; then
|
||||||
|
exec init
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Fallback: spawn a shell
|
||||||
|
exec cttyhack sh
|
||||||
Reference in new issue
Block a user