Local
The local package runs on your own machine. One command pushes your folder of crons up to the server, then pulls the server's logs back down and builds pages you can browse. It reads a small config file that names your server and where your crons live.
Get the local package
Download cronhoster-local-0.1.0.zip and unzip it. You get a
versioned cronhoster-local-0.1.0/ folder with everything it needs inside. It needs Node v20 or
newer.
curl -O https://cronhoster.org/downloads/cronhoster-local-0.1.0.zip
unzip cronhoster-local-0.1.0.zip
cd cronhoster-local-0.1.0
config.json
The scripts read a config.json you create from the bundled
config.example.json. It names your server, the token that reaches it, and the two folders
the scripts read and write. Point a script at it with the --config option.
{
"cronhoster-config-serverAddress": "203.0.113.5",
"cronhoster-config-apiToken": "the token the installer printed",
"cronhoster-config-contentRoot": "/home/you/cronhoster/crons",
"cronhoster-config-tools": "/home/you/cronhoster/_tools"
}
config.example.json to config.json and fill in your values.| Name | Type | Description |
|---|---|---|
cronhoster-config-serverAddress | address | Your server's IP address. Caddy fronts the API there, and the scripts reach it over HTTPS. |
cronhoster-config-apiToken | string | The API token the server installer printed. It is the one secret, so keep config.json private. |
cronhoster-config-contentRoot | path | An absolute path to your folder of cron directories. This is the folder the sync pushes up. |
cronhoster-config-tools | path | An absolute path where the log browser pages are written. Open the pages there in a browser. |
Sync your crons
Run the command with --sync to push your cron directories up to the
server. Pass the full absolute path to your config.
node cronhoster-local.js --config /path/to/config.json --sync
Sync is once per directory. A cron directory is uploaded whole the first time it appears, then never
re-synced. Entries whose name starts with _ or a dot never sync. See the
Crons page for authoring a cron, and
reference/hoster/sync for how the sync works.
The log browsers
The same command mirrors the server's logs and builds static pages you can browse under your configured
tools folder.
node cronhoster-local.js --config /path/to/config.json --sync --web-logs --server-logs --cron-logs
Pass --all in place of the three --*-logs flags to build every browser. The
Tools section shows what each page looks like.