Runs processes on a schedule and monitors results.
This is mostly intended to run in user space.
$ kin log job-id status start end pid duration --------------------------------------------------------------------------------------------------- sync-to-backup-NeP8nb4q OK 13:54 ->- 13:55 353842 1m 18s ER: raise-exception-NePaHZyV ER 14:00 ->- 14:00 353983 2s ER: print-output-NePaIKni ER 14:00 ->- 14:00 354000 2s check-free-mem-NePb7aPc OK 14:01 ->- 14:01 354026 2s
(If the line begins with ER: there was error output, but the job may have returned/completed successfully - for this see the status column)
kin start |
Install and start the kin server |
kin log |
List job runs |
kin edit |
Edit job definitions |
kin list |
List job definitions |
kin run <jobname> |
Run a job by its name |
kin help |
See available commands |
kin jl <job_id> |
Fetch a job run’s log |
Any .toml file in ~/.pm_dir
will be loaded. Example config.toml:
[print-output] schedule="0 13 * * *" command="python -c 'print(\"hello\");raise Exception(\"2\")'" [hello] command="echo hello"
So to run the "hello" job from the command line, you can run kin run hello
[suitably-involved-command] <-- jobname command="cd $HOME/somewhere && getparams.sh | run_program" <-- command to run schedule="0 18 * * *" <-- cron schedule to run at, optional next="hello" <-- job to run next (comma delimited list ok) error="print-output" <-- (comma delimited list ook) timeout=5000 <-- max run length in seconds
The kin executable file can be downloaded from the RELEASES page and stored in your path (e.g. $HOME/bin
)
then running kin start
will install and activate a user service