nanobox
nanobox copied to clipboard
Enhance log fetching
Utilize logvac's time filtering (start, stop, limit) in the cli.
Usage might look something like this:
# get a date range
nanobox log --start="Mon Aug 28 23:05:30 2017" --stop="Mon Aug 29 03:05:30 2017"
# get 30 minutes of logs starting at date/time
nanobox log --start="Mon Aug 28 23:05:30 2017" --limit="30m"
# get 3000 log lines starting at date/time
nanobox log --start="Mon Aug 28 23:05:30 2017" --limit="3000"
Does logvac support filtering by component and/or logger ID? These values are displayed, so they're definitely stored, but they might not be exposed for filtering against. It would be really useful to be able to say nanobox log -n 20 -f --component="data.db" --logger="cron*" to get the last 20 cronjob outputs on data.db, and continue streaming any new ones that pop up (as one example).
Logvac exposes much for filtering, so yes for historic. I'm fairly sure that level of filtering can also work for streaming as well, but would have to double check.
Also, print 10 lines by default with -f so we can see that it's doing something