Fly.ioAnnouncement
Flyctl meets JSON
Summary
Flyctl adds a --json, or -j, flag that presents command output as JSON to support automation around Fly applications. For GraphQL-backed commands it emits the API data, while logs become structured JSON and deployment progress arrives as a stream of Source/Status/Message objects. The post demonstrates piping flyctl list apps --json through jq to filter fields, convert hostnames and statuses to CSV, and select undeployed apps whose names feed xargs flyctl info --json -a; jq -s then gathers the resulting objects into an array. Because deployment output currently mixes JSON with non-JSON messages, the post recommends using --detach and polling flyctl status or running flyctl monitor instead of relying on the JSON stream for deployment monitoring.
Context
The new flag is intended to enable custom automation solutions for workflows involving Fly applications, including processing command output for other applications and management platforms.
Approach / What changed
Flyctl adds --json, short for -j, and emits JSON for command results, structured logs, and deployment progress messages. The examples use jq to filter, reshape, convert, and collect the output, while deployment monitoring uses --detach with status polling or flyctl monitor.
Takeaways
flyctl list apps --json returns an array containing application ID, name, status, deployment state, hostname, and organization.
jq can transform Flyctl JSON into CSV, filter applications with .Deployed==false, and use xargs to run flyctl info --json for each matching app.
Deployment JSON is currently mixed with non-JSON messages, so the post advises against using that stream for monitoring and recommends --detach, flyctl status, or flyctl monitor.
Source and freshness
- Source
- fly.io
- Published
- Added to Yomu
- Last updated
Summaries are generated from the original by a language model. Check the original before relying on it.
Keep reading
Related reading
The Good Stuff
Paid picks we use ourselves. Links carry a referral code — a subscription through one earns us a commission at no extra cost to you.
The best engineering reads, once a week
One useful email. Unsubscribe anytime.