Compare commits
No commits in common. "bb8a41725a0c97fd3e4300f1fad476f4ec0b5be4" and "bd24117af6c18e6f5f0f3106fb89ef3139be5c15" have entirely different histories.
bb8a41725a
...
bd24117af6
3 changed files with 5 additions and 34 deletions
|
|
@ -1,3 +0,0 @@
|
||||||
#!/usr/bin/env sh
|
|
||||||
|
|
||||||
exec vlogger -t goimapnotify -p daemon
|
|
||||||
|
|
@ -1,31 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
# conf can take:
|
|
||||||
# CONFIG_FILE = full path to goimapnotify config file to be used
|
|
||||||
# PROFILE = name of yaml file in goimapnotify config dir (without extension)
|
|
||||||
# THROTTLE_RATE = amount of time to wait before retrying if connection fails
|
|
||||||
DEFAULT_PROFILE="goimapnotify"
|
|
||||||
DEFAULT_THROTTLE_RATE=10
|
|
||||||
|
|
||||||
set -e
|
|
||||||
|
|
||||||
#shellcheck disable=SC1091
|
|
||||||
[ -r ./conf ] && . ./conf
|
|
||||||
|
|
||||||
if [ "$CONFIG_FILE" != "" ]; then
|
|
||||||
config_path="$CONFIG_FILE"
|
|
||||||
else
|
|
||||||
config_dir="${XDG_CONFIG_HOME:-$HOME/.config}"
|
|
||||||
config_path="${config_dir}/goimapnotify/${PROFILE:-$DEFAULT_PROFILE}.yaml"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Throttle before running watcher
|
|
||||||
snooze -H /1 -M /1 -S /1 -t timefile -T "${THROTTLE_RATE:-$DEFAULT_THROTTLE_RATE}" || exit 1
|
|
||||||
touch timefile
|
|
||||||
|
|
||||||
if [ ! -f "$config_path" ]; then
|
|
||||||
echo "Config path not found: $config_path"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "starting program"
|
|
||||||
exec chpst -e "$TURNSTILE_ENV_DIR" goimapnotify -conf "$config_path" 2>&1
|
|
||||||
5
services/sv/turnstile-ready/run
Executable file
5
services/sv/turnstile-ready/run
Executable file
|
|
@ -0,0 +1,5 @@
|
||||||
|
#!/bin/sh
|
||||||
|
[ -r ./conf ] && . ./conf
|
||||||
|
[ -n "$core_services" ] && SVDIR=".." sv start $core_services
|
||||||
|
[ -p "/run/turnstiled/1000/ready" ] && printf "/home/marty/.local/state/service/turnstile-ready" > "/run/turnstiled/1000/ready"
|
||||||
|
exec pause
|
||||||
Loading…
Add table
Add a link
Reference in a new issue