Skip to main content

Another YAML-based scheduler

Project description

Cronico

Cronico is a lightweight, YAML-based task scheduler for Unix-like systems.

It lets you define recurring jobs with flexible cron expressions — supporting traditional minute-based syntax, extended formats with seconds, and common shorthand aliases (@daily, @hourly, etc.).

Tasks can include:

  • Retry policies with configurable attempts.
  • Timeouts to kill long-running processes.
  • Environment injection from .env files or inline variables.
  • Working directory control per task.
  • Streaming or buffered logs for stdout/stderr.

Cronico is designed to run as a long-lived daemon (via systemd or similar) and can reload its configuration on SIGHUP without restarting the process.

tasks:
  # Classic: every 5 minutes
  example_task:
    cron: "*/5 * * * *"
    command: "echo 'Hello, World!'"
    retry_on_error: true
    max_attempts: 3
    env_file: ".env"
    timeout: 60  # seconds
    working_dir: "/path/to/dir"
    environment:
      MY_VAR: "value"

  # Extended with seconds: every minute, at the 10th second
  every_minute_at_second_10:
    cron:
      minute: "*"
      hour: "*"
      day: "*"
      month: "*"
      weekday: "*"
      second: 10
    command: "echo 'Run at second 10 of every minute'"

  # Classic with seconds: every 30 seconds
  every_30_seconds:
    cron: "*/1 * * * * 0,30"
    command: "echo 'This runs at second 0 and 30 of each minute'"

  # Daily at 03:00:15
  daily_with_seconds:
    cron:
      minute: 0
      hour: 3
      day: "*"
      month: "*"
      weekday: "*"
      second: 15
    command: "echo 'Daily at 03:00:15'"

  # Shorthand: daily, at 00:00
  short_hand:
    cron: "@daily"
    command: |
        echo "Supported aliases:"
        echo "- @yearly: 0 0 1 1 *"
        echo "- @annually: 0 0 1 1 *"
        echo "- @monthly: 0 0 1 * *"
        echo "- @weekly: 0 0 * * 0"
        echo "- @daily: 0 0 * * *"
        echo "- @midnight: 0 0 * * *"
        echo "- @hourly: 0 * * * *"

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cronico-0.9.8.tar.gz (7.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cronico-0.9.8-py3-none-any.whl (7.3 kB view details)

Uploaded Python 3

File details

Details for the file cronico-0.9.8.tar.gz.

File metadata

  • Download URL: cronico-0.9.8.tar.gz
  • Upload date:
  • Size: 7.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for cronico-0.9.8.tar.gz
Algorithm Hash digest
SHA256 c970a9546f1c8ff7adce3f7aaf9e491a540b365a103997566ff4d85c00fe0dba
MD5 8ea349379170a237c77605513cfeae9f
BLAKE2b-256 cce3a9adc60122d26801e48a3600073c8e66bf37bc6395d66de96aa178fcd642

See more details on using hashes here.

File details

Details for the file cronico-0.9.8-py3-none-any.whl.

File metadata

  • Download URL: cronico-0.9.8-py3-none-any.whl
  • Upload date:
  • Size: 7.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for cronico-0.9.8-py3-none-any.whl
Algorithm Hash digest
SHA256 6b9abb0ad092fa8f3cfcd48b7e2f832500f92991eb599508ecdf3b349c25fe1d
MD5 3a88ade5383c69352ae4aa75ca5599ff
BLAKE2b-256 e427ed27abb69b357628320a41026f2080a1267657ea422d76419070b41fb179

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page