33 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			Bash
		
	
	
	
			
		
		
	
	
			33 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			Bash
		
	
	
	
#!/hint/bash
 | 
						|
# Copyright (C) 2023  Umorpha Systems
 | 
						|
# SPDX-License-Identifier: AGPL-3.0-or-later
 | 
						|
 | 
						|
build() {
 | 
						|
	add_module 'overlay'
 | 
						|
 | 
						|
	add_binary umorpha-mount
 | 
						|
	add_runscript
 | 
						|
}
 | 
						|
 | 
						|
help() {
 | 
						|
	cat <<HELPEOF
 | 
						|
This hook mounts a read-only root filesystem with a persistent
 | 
						|
overlayfs on top of it.
 | 
						|
 | 
						|
Standard mkinitcpio boot parameters: 
 | 
						|
  ro / rw         default: 'ro'     whether to mount the 'overlay' device
 | 
						|
                                    and (if if there is one) the 'boot'
 | 
						|
                                    device read-only or read+write
 | 
						|
  root            required          device of the read-only root filesystem
 | 
						|
  rootfstype      default: 'auto'   filesystem type of the 'root' device
 | 
						|
  rootflags       default: empty    mount options for the 'root' device
 | 
						|
Additional boot parameters:
 | 
						|
  overlay         required          device of the persistent overlay filesystem
 | 
						|
  overlayfstype   default: 'auto'   filesystem type of the 'overlay' device
 | 
						|
  overlayflags    default: empty    mount options for the 'overlay' device
 | 
						|
  boot            default: none     device of the '/boot' filesystem
 | 
						|
  bootfstype      default: 'auto'   filesystem type of the 'boot' device
 | 
						|
  bootflags       default: empty    mount options for the 'boot' device
 | 
						|
HELPEOF
 | 
						|
}
 |