https://github.com/system64fumo/rc-scripts
sysvinit style rc scripts
https://github.com/system64fumo/rc-scripts
busybox init-system rc-script shell-scripts sysvinit
Last synced: 9 months ago
JSON representation
sysvinit style rc scripts
- Host: GitHub
- URL: https://github.com/system64fumo/rc-scripts
- Owner: System64fumo
- Created: 2024-05-29T05:13:22.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-02-02T07:48:04.000Z (11 months ago)
- Last Synced: 2025-03-27T20:49:08.932Z (9 months ago)
- Topics: busybox, init-system, rc-script, shell-scripts, sysvinit
- Language: Shell
- Homepage:
- Size: 40 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# rc-scripts
This repository holds the rc scripts that i use on my systems
# Installation
To install and use these scripts on your system you need to do the following:
1. `mkdir /opt/busybox`
2. Download busybox and put it in /opt/busybox
3. Install busybox by either symlinking or running `/opt/busybox/busybox --install -s /opt/busybox/`
4. `git clone https://github.com/System64fumo/rc-scripts`
5. `sudo mv ./rc-scripts/rc.d /etc/rc.d`
6. `sudo mv ./rc-scripts/inittab /etc/inittab`
7. `sudo rm /bin/{init,poweroff,reboot}`
8. `sudo ln -s /opt/busybox/init /bin/init`
9. `sudo ln -s /opt/busybox/poweroff /bin/poweroff`
10. `sudo ln -s /opt/busybox/reboot /bin/reboot`
Do note: After following the installation guide,
You will not be able to reboot your system normally for the first time (Since we replaced the original poweroff file)
Also any updates to your init system of choice will restore the original init,
So add your init system to your package manager's ignore/block list.
# Configuration and usage
To manually start or stop a service, Run the `service` script.
Example: `sudo /etc/rc.d/script start sshd`
To configure which services load when you boot the system up,
Edit `/etc/rc.d/init`.
To configure what happens when you shut the system down,
Edit `/etc/rc.d/shutdown`.
To configure service settings, (Such as zram size, Network details, ect..)
Edit `/etc/rc.d/config`.
To configure ttys or autologin, (The default autologin is for root on tty1)
Edit `/etc/inittab`.
# Additional information
By default the service loader will use busybox,
Uncomment the export line in `/etc/rc.d/service` to use native system bins if you wish.
The splash screen configuration `/etc/rc.d/splash/fbsplash.ini` assumes your monitor resolution is 1080p.
> [!IMPORTANT]
> The default configuration assumes a lot, Such as:
> Running on a non systemd based distro
> Connected via ethernet on eth0 with a static ip addr
> Using pipewire for audio
> Please change it to match your system and your needs.
> [!NOTE]
> Some services should not run as the root user (Such as audio for example)
> You can use `su` to start them automatically in `/etc/rc.d/init`
# Why do any of this? And why busybox?
The following answers are based on my opinion, Feel free to disagree.
I personally like the way sysvinit style init systems work (Shell script based init systems)
I find it easier to configure and do everything i want this way too
The speed and performance of existing init systems did not satisfy me.
As for the busybox question, Honestly?
I just wanted to mess around with busybox a while back and tried it's init system, So it kinda stuck
I am fully aware that busybox is not exactly the best thing out there,
However i'm too lazy to switch to something else