Product
Logs
Stackap serves two logs for every project, the output of the latest build and the live output of the running app, both readable from one command or one API call.
What it does
The build log is everything the latest build printed, stored with that build: dependency installation, your build script, and Stackap's own lines such as which project type it detected and what it generated. It is the first place to look when a deploy does not go live.
The runtime log is a live tail of what the running containers print. When a project runs several copies, it collects from every running copy. If no container is running, it falls back to the stored deployment events, so there is still something to read after a crash.
Both are read the same way, by an agent or a person, with stackap logs <slug> --source build|runtime --limit N. The default is the 200 most recent lines and the maximum is 5,000.
How it works
Logs go through the same authentication as everything else, so a token only reads its own organization's projects. A project that belongs to someone else returns the same not-found response as one that does not exist.
Container logs rotate at 10 MB with three files kept, which stops a chatty app from filling the disk. That setting applies to containers created after it was introduced, so a long-running older container keeps its previous behavior until it is next deployed.
The usual loop for an agent is short: deploy, read the build log, change the code if the build failed, and read the runtime log if the build passed but the health check did not.
In practice
$ stackap logs my-app --source build $ stackap logs my-app --source runtime --limit 500
Early-access scope
- Build logs are served for the latest build only. Older builds' logs are stored but are reachable through the API by build id, not through this command.
- Runtime logs are a bounded tail, not an archive. Past the rotation limit, older lines are gone.
- There is no search, no filtering by level and no streaming to an outside log service.
- Database logs are not supported yet, and the API says so when asked.
- Logs are not backed up.
Questions
Can I follow logs live?
Where do request metrics go?
Stackap is in early access. Tell us what you run and we will reply with a straight answer about whether it fits.
Ask for an invitationLast updated .