Cloud Deployment
Deploying a loop to the hosted runner lets it execute even when your laptop is offline. The hosted scheduler now orchestrates queueing, locking, and retries by default—you simply provide a cron trigger.
Prerequisites
- Authenticated CLI (
loopcli auth login) - An active project (
loopcli project listto confirm) - Hosted runner credentials configured in the dashboard
Deploy a loop
loopcli loop deploy daily-report --schedule "0 14 * * *" --activate
--scheduleaccepts standard cron syntax in UTC.--activateflips the loop to run automatically. Use--disableto pause.
Queue and monitor executions
loopcli loop run daily-report --cloud --wait --json
The CLI waits for completion and prints the final execution payload. Use loopcli loop wait <executionId> to monitor from another terminal.
How scheduling works
LoopCLI's hosted orchestrator continuously claims due schedules, enqueues executions, records audit logs, and advances next_run_at. You just need a cron-like trigger that pings the platform.
Provide the cron trigger
- Set
RUNNER_WORKER_SECRETin the dashboard environment. This shared secret authenticates your cron provider. - Configure a minute-based job in your preferred service (Vercel Cron, GitHub Actions, Cloudflare Workers, etc.) to call:
POST https://app.loopcli.com/api/internal/scheduler/runPOST https://app.loopcli.com/api/internal/runner/processIncludeAuthorization: Bearer $RUNNER_WORKER_SECRET(orX-Runner-Secret) on both requests.
Tip: the dashboard Scheduling tab shows ready-made examples, and
loopcli loop worker:scheduleprints the same curl/JSON snippets for copy-paste.
What the orchestrator handles for you
- Claims due schedules with safe locking so overlapping cron pings are fine.
- Enqueues executions with metadata that matches the loop + project.
- Logs every attempt and automatically advances the next run window.
- Routes work to hosted runners so you can scale worker invocations independently.
Optional manual commands
These CLI commands remain useful for debugging complex setups:
loopcli loop scheduler:run— claim schedules immediately (honorsRUNNER_WORKER_SECRET).loopcli loop worker:run— process a single queued execution.- Dashboard + CLI loop views expose the stored cron expression, timezone, and last/next run timestamps for quick inspection.
Troubleshooting
- Execution stuck in
queued: verify both the scheduler and worker cron jobs are firing with the correct secret. - Scheduler shows
queued_with_warning: open the dashboard logs to inspect recent schedule runs; usually this indicates a schedule metadata update failed after queuing. - Error
RUNNER_WORKER_SECRET missing: set the secret in the dashboard environment. - Rate limiting: reduce concurrency or add retries on the HTTP steps.