-
-
Notifications
You must be signed in to change notification settings - Fork 910
Running in background
Jacob Lundqvist edited this page Jul 9, 2024
·
7 revisions
Location tracking is enabled through /dev/location
. Reading from this device will start tracking your location and output a line each time your location updates. This prevents iSH from suspending when in the background.
You can get the app to run in the background with the following command:
cat /dev/location > /dev/null &
To stop running in the background:
killall -9 cat
If you use services and OpenRC, here is a service script that automates the task at every startup. Save it as /etc/init.d/runbg
.
Then add the script to your startup services:
rc-update add runbg default
Replace default
with sysinit
if you don't want to switch to the default runlevel in your inittab
.
#!/sbin/openrc-run
#
# Copyright (c) 2021-2024: [email protected]
# License: MIT
#
# This service reads the GPS and discards the output to /dev/null.
# This is not tracking you in any way. The sole purpose of this
# is to ensure an iOS program continues to run in the background.
# This process has no noticeable impact on battery life.
#
description="Reads GPS to ensure iSH continues to run in the background"
command="/bin/cat"
command_args="/dev/location > /dev/null"
command_background="YES"
pidfile="/run/runbg.pid"
- Contributing to iSH Development
- How to add a new Character Device to iSH
- How to add a new entry to /proc/ish
- Fixing hostname localhost
- Running nmap
- Running Ruby Programs
- Installing PHP with a TLS certificate and a PHP filemanager
- Installing R and any package from the CRAN
- iSH Alpine Release Issues
- Using Alpine Linux repositories
- Upgrading to a new release
- Install & Activate Alternate Filesystems