Update alpine_chroot/readme.md

This commit is contained in:
2025-09-03 07:11:57 +00:00
parent 67b32ce166
commit ea80deba97

View File

@@ -8,7 +8,18 @@
* Navigate to `/data` and then run `sh setup.sh` which should setup the chroot (mounting the `/dev` etc)
* This will then drop you into a `localhost` shell, to get out
### Start Up Scripts
* To start up a binary we need to insert a script somewhere in the start up procedure, I noted that the binary `debuggerd` is started and didn't think we needed this so instead replaced the binary with a shell script that would start my own programs.
* Android mounts its `/system/bin` as read only so it is necessary to temporarily remount this to make the changes:
* `mount -o remount,rw /system`
* `chmod o+w /system/bin`
* Backup debuggerd binary and then replace it with the shell script
* `chmod o-w /system/bin`
* `mount -o remount,ro /system`
### Links
* [alpine-minirootfs](https://dl-cdn.alpinelinux.org/alpine/v3.22/releases/armv7/alpine-minirootfs-3.22.1-armv7.tar.gz)
* [Setting up chroot](https://wiki.alpinelinux.org/wiki/Alpine_Linux_in_a_chroot)
* [Setting up chroot](https://wiki.alpinelinux.org/wiki/Alpine_Linux_in_a_chroot)
* [android - changing system permissions](https://iamcmotc.blogspot.com/2015/04/android-how-to-run-script-or-system.html)