Skip to content

Repository files navigation

Rally

Rally launches the commands in rally.toml, captures their output, and serves a local dashboard so you can see what is running and start, stop, or restart each app.

Rally 2.0 is a clean break from 1.x. It does not read the old configuration format. See SPEC.md for the full contract and USER_GUIDE.md for day-to-day use.

This README is also the crates.io crate page for frogfish-rally.

Quick start

macrun = ["myapp", "development"]

[apps.database]
run = ["postgres", "-D", "./data"]

[apps.api]
run = ["cargo", "run", "-p", "api"]
after = ["database"]
open = "http://localhost:8080"

[apps.web]
run = ["npm", "run", "dev"]
after = ["api"]
open = "http://localhost:3000"
rally

Open http://127.0.0.1:7700.

If macrun is set, Rally launches each app as:

macrun run myapp development -- cargo run -p api

If macrun is omitted, Rally runs the command directly. Secrets never enter rally.toml, the API, or the dashboard.

Configuration

Rally reads ./rally.toml unless you pass --config PATH. Relative paths and child-process working directories are resolved from the directory that contains that file.

Each app has at most three fields:

Field Required Meaning
run yes Argv array. The first item is the executable.
after no App names that must be launched first.
open no http:// or https:// link shown in the dashboard.

after is launch order only. Rally does not wait for ports, health checks, or readiness. If an app must wait until a dependency can accept connections, put that wait in the app's own command.

Starting one app also starts any missing prerequisites. Stopping one app does not stop its dependents. Shutting Rally down stops dependents first.

Unknown fields are errors. Rally 1.x keys such as command, [env], watch, and health_url are not supported.

CLI

rally
rally --config FILE
rally --port 7700
rally start APP
rally stop APP
rally restart APP

--version prints {VERSION}+build-{BUILD}. --copyright prints the SPDX copyright and license lines.

The dashboard always binds to 127.0.0.1. Control commands talk to an already running Rally instance on that port.

HTTP API

Method Path Description
GET /api/status Process statuses and captured logs
POST /api/start/:name Start an app and missing prerequisites
POST /api/stop/:name Stop one app
POST /api/restart/:name Restart one app
GET /api/events Server-Sent Events stream

On stop, Rally sends a graceful signal and then force-kills the process after five seconds.

Installation

The published crate name is frogfish-rally. The command remains rally.

From crates.io:

cargo install frogfish-rally

From this checkout:

cargo install --path .

License

GPL-3.0-or-later. See LICENSE and LICENSING.md.

About

Run and manage your local dev stack from a single rally.toml

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages