mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-30 12:11:56 +00:00
Bugfix/disable uasp (#878)
* usbstoraged * set quirks on demand * remove reference to usbstoraged.service * comments * use sysfs instead of modprobe and address comments * fix ro fs and missing comma * Apply suggestions from code review * don't recurse overlayroot * sleep before reconnect * reset twice * sync between writes * fix build * fix build * adds drive to storage quirk whitelist * long sleep * another thing to try * fix: Ensure that the changes take effect Co-authored-by: Keagan McClelland <keagan.mcclelland@gmail.com> Co-authored-by: Justin Miller <dragondef@gmail.com>
This commit is contained in:
3
build/fstab
Normal file
3
build/fstab
Normal file
@@ -0,0 +1,3 @@
|
||||
LABEL=green / ext4 discard,errors=remount-ro 0 1
|
||||
LABEL=system-boot /media/boot-rw vfat defaults 0 1
|
||||
/media/boot-rw /boot/firmware none defaults,bind,ro 0 0
|
||||
@@ -47,7 +47,7 @@ ControlPort 9051
|
||||
CookieAuthentication 1
|
||||
EOF
|
||||
|
||||
echo 'overlayroot="tmpfs"' > /etc/overlayroot.local.conf
|
||||
echo 'overlayroot="tmpfs":swap=1,recurse=0' > /etc/overlayroot.local.conf
|
||||
systemctl disable initialization.service
|
||||
sync
|
||||
reboot
|
||||
|
||||
@@ -21,8 +21,11 @@ sudo e2label ${OUTPUT_DEVICE}p4 blue
|
||||
mkdir -p /tmp/eos-mnt
|
||||
sudo mount ${OUTPUT_DEVICE}p1 /tmp/eos-mnt
|
||||
|
||||
sudo sed -i 's/^/usb-storage.quirks=152d:0562:u /g' /tmp/eos-mnt/cmdline.txt
|
||||
sudo sed -i 's/LABEL=writable/LABEL=green/g' /tmp/eos-mnt/cmdline.txt
|
||||
# create a copy of the cmdline *without* the quirk string, so that it can be easily amended
|
||||
sudo cp /tmp/eos-mnt/cmdline.txt /tmp/eos-mnt/cmdline.txt.orig
|
||||
sudo sed -i 's/^/usb-storage.quirks=152d:0562:u /g' /tmp/eos-mnt/cmdline.txt
|
||||
|
||||
cat /tmp/eos-mnt/config.txt | grep -v "dtoverlay=" | sudo tee /tmp/eos-mnt/config.txt.tmp
|
||||
echo "dtoverlay=pwm-2chan" | sudo tee -a /tmp/eos-mnt/config.txt.tmp
|
||||
sudo mv /tmp/eos-mnt/config.txt.tmp /tmp/eos-mnt/config.txt
|
||||
@@ -35,8 +38,8 @@ sudo umount /tmp/eos-mnt
|
||||
|
||||
sudo mount ${OUTPUT_DEVICE}p3 /tmp/eos-mnt
|
||||
|
||||
sudo sed -i 's/LABEL=writable/LABEL=green/g' /tmp/eos-mnt/etc/fstab
|
||||
sudo sed -i 's/LABEL=system-boot\(\s\+\S\+\s\+\S\+\s\+\)defaults/LABEL=system-boot\1defaults,ro/g' /tmp/eos-mnt/etc/fstab
|
||||
sudo mkdir /tmp/eos-mnt/media/boot-rw
|
||||
sudo cp build/fstab /tmp/eos-mnt/etc/fstab
|
||||
# Enter the appmgr directory, copy over the built EmbassyOS binaries and systemd services, edit the nginx config, then create the .ssh directory
|
||||
cd appmgr/
|
||||
|
||||
|
||||
Reference in New Issue
Block a user