{"id":21826976,"url":"https://github.com/lifailon/lazyjournal","last_synced_at":"2025-05-15T12:06:34.232Z","repository":{"id":262403789,"uuid":"887122539","full_name":"Lifailon/lazyjournal","owner":"Lifailon","description":"A TUI for reading logs from journald, auditd, file system, Docker containers, Podman and Kubernetes pods for quick viewing, coloring output and filtering with fuzzy find, regex support and timestamp.","archived":false,"fork":false,"pushed_at":"2025-04-19T12:40:51.000Z","size":18728,"stargazers_count":529,"open_issues_count":1,"forks_count":11,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-05-15T12:06:28.539Z","etag":null,"topics":["audit-log","auditd","bsd","docker-logs","go","gocui","journal","journalctl","journald","kubernetes-logging","log-analysis","log-monitor","log-parser","log-viewer","logging","logs","podman","regexp","syslog","tui"],"latest_commit_sha":null,"homepage":"https://pkg.go.dev/github.com/Lifailon/lazyjournal","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Lifailon.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-11-12T07:54:04.000Z","updated_at":"2025-05-15T10:22:48.000Z","dependencies_parsed_at":"2025-01-15T04:29:31.173Z","dependency_job_id":"7ce46e63-d39f-4e11-8863-4249b2995a4c","html_url":"https://github.com/Lifailon/lazyjournal","commit_stats":null,"previous_names":["lifailon/lazyjournal"],"tags_count":15,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lifailon%2Flazyjournal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lifailon%2Flazyjournal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lifailon%2Flazyjournal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lifailon%2Flazyjournal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Lifailon","download_url":"https://codeload.github.com/Lifailon/lazyjournal/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254337613,"owners_count":22054253,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["audit-log","auditd","bsd","docker-logs","go","gocui","journal","journalctl","journald","kubernetes-logging","log-analysis","log-monitor","log-parser","log-viewer","logging","logs","podman","regexp","syslog","tui"],"created_at":"2024-11-27T18:11:41.928Z","updated_at":"2025-05-15T12:06:29.202Z","avatar_url":"https://github.com/Lifailon.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n    \u003cimg src=\"/img/logo.jpg\"\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://github.com/Lifailon/lazyjournal/actions/workflows/build.yml\"\u003e\u003cimg title=\"Actions Build\"src=\"https://github.com/Lifailon/lazyjournal/actions/workflows/build.yml/badge.svg\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://raw.githubusercontent.com/wiki/Lifailon/lazyjournal/coverage.html\"\u003e\u003cimg title=\"Go coverage report\"src=\"https://raw.githubusercontent.com/wiki/Lifailon/lazyjournal/coverage.svg\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://goreportcard.com/report/github.com/Lifailon/lazyjournal\"\u003e\u003cimg src=\"https://goreportcard.com/badge/github.com/Lifailon/lazyjournal\" alt=\"Go Report\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://pkg.go.dev/github.com/Lifailon/lazyjournal\"\u003e\u003cimg src=\"https://pkg.go.dev/badge/github.com/Lifailon/lazyjournal.svg\" alt=\"Go Reference\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://github.com/Lifailon/Kinozal-Bot/blob/rsa/LICENSE\"\u003e\u003cimg title=\"License\"src=\"https://img.shields.io/github/license/Lifailon/Kinozal-Bot?logo=readme\u0026color=white\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://github.com/avelino/awesome-go\"\u003e\u003cimg src=\"https://awesome.re/mentioned-badge.svg\" alt=\"Mentioned in Awesome Go\"\u003e\u003c/a\u003e\n\u003cbr\u003e\n    \u003ca href=\"https://aur.archlinux.org/packages/lazyjournal\"\u003e\u003cimg title=\"Arch Linux\" src=\"https://img.shields.io/aur/version/lazyjournal?logo=arch-linux\u0026color=blue\u0026label=AUR\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://anaconda.org/conda-forge/lazyjournal\"\u003e\u003cimg title=\"Conda Forge\" src=\"https://img.shields.io/conda/vn/conda-forge/lazyjournal?logo=anaconda\u0026color=green\u0026label=Conda\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://formulae.brew.sh/formula/lazyjournal\"\u003e\u003cimg title=\"Homebrew\" src=\"https://img.shields.io/homebrew/v/lazyjournal?logo=homebrew\u0026color=yellow\u0026label=Homebrew\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://hub.docker.com/r/lifailon/lazyjournal\"\u003e\u003cimg title=\"Docker Hub\" src=\"https://img.shields.io/docker/image-size/lifailon/lazyjournal/latest?logo=docker\u0026color=blue\u0026label=Docker+Hub\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\nTerminal user interface for reading logs from `journalctl`, file system, Docker and Podman containers, as well Kubernetes pods for quick viewing and filtering with fuzzy find, regex support and coloring the output, written in Go with the [awesome-gocui](https://github.com/awesome-gocui/gocui) (fork [gocui](https://github.com/jroimartin/gocui)) library.\n\nThis tool is inspired by and with love for [LazyDocker](https://github.com/jesseduffield/lazydocker) and [LazyGit](https://github.com/jesseduffield/lazygit). It is also included in [Awesome-Go](https://github.com/avelino/awesome-go?tab=readme-ov-file#logging), [Awesome-TUIs](https://github.com/rothgar/awesome-tuis?tab=readme-ov-file#development) and [Awesome-Docker](https://github.com/veggiemonk/awesome-docker?tab=readme-ov-file#terminal-ui), check out other useful projects on the repository pages.\n\n![interface](/img/regex.png)\n\n## Features\n\n- Simple installation, to run download one executable file without dependencies and settings.\n- Centralized search for the required journal by filtering all lists (log sources).\n- Streaming output of new events from the selected journal (like `tail`).\n- List of all units (`services`, `sockets`, etc.) with current running status from `systemd` via `systemctl`.\n- View all system and user journals via `journalctl` (tool for reading logs from [journald](https://github.com/systemd/systemd/tree/main/src/journal)).\n- List of all system boots for kernel log output.\n- File system logs such as for `Apache` or `Nginx`, as well as `syslog`, `messages`, etc. from `/var/log`.\n- Lists all log files in users home directories, as well as descriptor log files used by processes.\n- Reading archive logs truncated during rotation (`gz`, `xz` and `bz2` formats), Packet Capture (`pcap` format) and Apple System Log (`asl` format).\n- Docker containers (including `timestamp` and `stderr`), Podman pods and the Docker Swarm services.\n- Kubernetes pods via `kubectl`.\n- Windows Event Logs via `PowerShell` and `wevtutil`, as well as application logs from Windows file system.\n\nSupports 3 filtering modes:\n\n- **Default** - case sensitive exact search.\n- **Fuzzy** (like `fzf`) - custom inexact case-insensitive search (searches for all phrases separated by a space anywhere on a line).\n- **Regex** (like `grep`) - search with regular expression support, based on the built-in [regexp](https://pkg.go.dev/regexp) library, case-insensitive by default (in case a regular expression syntax error occurs, the input field will be highlighted in red).\n\n## Coloring\n\nSupported coloring groups for output:\n\n- **Custom** - URLs, file paths and processes in UNIX.\n- **Yellow** - known names (host name and system users) and warnings.\n- **Green** - keywords indicating success.\n- **Red** - keywords indicating error.\n- **Blue** - statuses (info, debug, etc), actions (install, update, etc) and HTTP methods (GET, POST, etc).\n- **Light blue** - numbers (date, time, bytes, versions, percentage, integers, IP and MAC addresses).\n\nA full list of all keywords can be found in the [color.log](/color.log) file (used for testing only). If you have suggestions for improving coloring (e.g. adding new words), you can open an [issue](https://github.com/Lifailon/lazyjournal/issues) for a new feature. \n\nColoring directly affects the loading time of the log, to increase the performance of reading large logs, it is possible to disable coloring using the `Ctrl+Q`.\n\n## Install\n\nBinaries are available for download on the [releases](https://github.com/Lifailon/lazyjournal/releases) page.\n\nList of supported systems and architectures in which functionality is checked: \n\n| OS        | amd64 | arm64 | Systems                                                                                                                               |\n| -         | -     | -     | -                                                                                                                                     |\n| Linux     | ✔     |  ✔   | Raspberry Pi (`aarch64`), Oracle Linux (RHEL-based in WSL environment), Arch Linux, Rocky Linux, Ubuntu Server 20.04.6 and above.    |\n| Darwin    | ✔     |  ✔   | macOS Sequoia 15.2 `x64` on MacBook and the `arm64` in GitHub Actions.                                                               |\n| BSD       | ✔     |       | OpenBSD 7.6 and FreeBSD 14.2.                                                                                                        |\n| Windows   | ✔     |       | Windows 10 and 11.                                                                                                                   |\n\n### Unix-based\n\nRun the command in the console to quickly install or update the stable version for Linux, macOS or the BSD-based system:\n\n```shell\ncurl -sS https://raw.githubusercontent.com/Lifailon/lazyjournal/main/install.sh | bash\n```\n\nThis command will run a script that will download the latest executable from the GitHub repository into your current user's home directory along with other executables (or create a directory) and grant execution permission.\n\nOr you can install manually from `deb` or `snap` package:\n```bash\ncurl -L -sS https://github.com/Lifailon/lazyjournal/releases/download/0.7.7/lazyjournal-0.7.7-amd64.deb -o /tmp/lazyjournal.deb\nsudo dpkg -i /tmp/lazyjournal.deb\n\ncurl -L -sS https://github.com/Lifailon/lazyjournal/releases/download/0.7.7/lazyjournal-0.7.7-amd64.snap -o /tmp/lazyjournal.snap\nsudo snap install /tmp/lazyjournal.snap --dangerous --classic\n```\n\n### Arch Linux\n\nIf you an Arch Linux user you can also install from the [AUR](https://aur.archlinux.org/packages/lazyjournal):\n\n```shell\nparu -S lazyjournal\n```\n\n### Conda / mamba / pixi (Linux / macOS / Windows)\n\nIf you use package managers like conda or mamba, you can install `lazyjournal` from [conda-forge](https://anaconda.org/conda-forge/lazyjournal):\n\n```shell\nconda install -c conda-forge lazyjournal\nmamba install -c conda-forge lazyjournal\n```\n\nYou can install `lazyjournal` user-globally using [pixi](https://prefix.dev):\n\n```shell\npixi global install lazyjournal\n```\n\n### Homebrew (macOS / Linux)\n\nUse the following command to install `lazyjournal` using [Homebrew](https://formulae.brew.sh/formula/lazyjournal):\n\n```shell\nbrew install lazyjournal\n```\n\n### Docker (Debian-based)\n\nTo run the interface in a container, download [docker-compose](/docker-compose.yml) and use the image from [Docker Hub](https://hub.docker.com/r/lifailon/lazyjournal):\n\n```shell\nmkdir lazyjournal \u0026\u0026 cd lazyjournal\ncurl -sS https://raw.githubusercontent.com/Lifailon/lazyjournal/main/docker-compose.yml -o docker-compose.yml\ndocker-compose up -d\ndocker exec -it lazyjournal lazyjournal\n```\n\nThe image is based on Debian with `systemd` and docker cli pre-installed. The necessary **read-only** permissions are already preset in `docker-compose` to support all log sources from the host system (review it to customize for your individual use).\n\nSupports running in the web interface via [ttyd](https://github.com/tsl0922/ttyd) and mouse control. To do this, edit the variables in the `.env` file:\n\n```shell\nTTYD=true\nPORT=5555\n# Credentials for accessing the Web interface (optional)\nUSERNAME=admin\nPASSWORD=admin\n```\n\n### Windows\n\nUse the following command to quickly install in your PowerShell console:\n\n```PowerShell\nirm https://raw.githubusercontent.com/Lifailon/lazyjournal/main/install.ps1 | iex\n```\n\nThe following directories are used to search for logs in the file system:\n\n- `Program Files`\n- `Program Files (x86)`\n- `ProgramData`\n- `AppData\\Local` and `AppData\\Roamin` for current user\n\nTo read logs, automatic detection of the following encodings is supported:\n\n- `UTF-8`\n- `UTF-16 with BOM`\n- `UTF-16 without BOM`\n- `Windows-1251` by default\n\n### Go Package\n\nYou can also use Go for install the dev version ([Go](https://go.dev/doc/install) must be installed in the system):\n\n```shell\ngo install github.com/Lifailon/lazyjournal@latest\n```\n\n## Usage\n\nYou can run the interface from anywhere:\n\n```\nlazyjournal                        Run interface\nlazyjournal --help, -h             Show help\nlazyjournal --version, -v          Show version\nlazyjournal --audit, -a            Show audit information\nlazyjournal --tail, -t             Change the number of log lines to output (default: 100000, range: 5000-200000)\nlazyjournal --update, -u           Change the auto refresh interval of the log output (default: 5, range: 2-10)\nlazyjournal --disable-color, -d    Disable output coloring\nlazyjournal --command-color, -c    Coloring in command line mode\n```\n\nAccess to all system logs and containers may require elevated privileges for the current user.\n\nIf your system uses [rsyslog](https://www.rsyslog.com) to collect logs from remote systems, you will be able to search for logs and analyze them from a single interface.\n\nInformation in the subtitle of the `Logs` window:\n\n- `tail` - maximum number of log lines to load.\n- `update` - current output auto-update status (disabled when manually scrolling the output).\n- `interval` - auto-update interval for output in seconds (file logs are updated only when there are changes).\n- `color` - whether the output coloring mode is currently enabled or disabled.\n\nAlso output coloring is supported in command line mode:\n\n```shell\nalias lj=lazyjournal\ncat /var/log/syslog | lj -c\n```\n\n## Build\n\nClone the repository and run the project:\n\n```shell\ngit clone https://github.com/Lifailon/lazyjournal\ncd lazyjournal\ngo run main.go\n```\n\nUse make or [go-task](https://github.com/go-task/task) to build binaries for different platforms and systems:\n\n```shell\nmake build\n# or\ntask build\n```\n\nCheck the source code on the base linters using [golangci-lint](https://github.com/golangci/golangci-lint) (including critic and security):\n\n```shell\nmake lint\n```\n\n## Testing\n\nUnit tests cover all main functions and interface operation.\n\n```shell\nmake list # get a list of all tests\nmake test n=TestMockInterface # run the selected test\n```\n\nThe test coverage report using CI Actions for Linux, macOS and Windows systems is available on the [Wiki](https://github.com/Lifailon/lazyjournal/wiki) page.\n\nTesting in BSD-based systems is done in a home environment using [usup](https://github.com/Lifailon/usup).\n\n## Hotkeys\n\n- `F1` - show help on hotkeys.\n- `Tab` - switch between windows.\n- `Shift+Tab` - return to previous window.\n- `Enter` - selection a journal from the list to display log output.\n- `Left/Right` - switch between journal lists in the selected window.\n- `\u003cUp/PgUp\u003e` and `\u003cDown/PgDown\u003e` - move up and down through all journal lists and log output, as well as changing the filtering mode in the filter window.\n- `\u003cShift/Alt\u003e+\u003cUp/Down\u003e` - quickly move up and down through all journal lists and log output every `10` or `100` lines (`500` for log output).\n- `\u003cShift/Ctrl\u003e+\u003cU/D\u003e` - quickly move up and down (alternative for macOS).\n- `Ctrl+A` or `Home` - go to top of log.\n- `Ctrl+E` or `End` - go to the end of the log.\n- `Alt+Left/Right` - change the number of log lines to output (default: `100000`, range: `5000-200000`).\n- `Shift+Left/Right` - change the auto refresh interval of the log output (default: `5`, range: `2-10`).\n- `Ctrl+Q` - enable or disable built-in output coloring.\n- `Ctrl+S` - enable or disable coloring via [tailspin](https://github.com/bensadeh/tailspin).\n- `Ctrl+R` - update all log lists.\n- `Ctrl+W` - clear text input field for filter to quickly update current log output.\n- `Ctrl+C` - exit.\n\n## Contributing\n\nSince this is my first Go project, there may be some bad practices, BUT I want to make `lazyjournal` better. Any contribution will be appreciated! If you want to implement any new feature or fix something, please [open an issue](https://github.com/Lifailon/lazyjournal/issues) first.\n\nThanks to all participants for their contributions:\n\n- [Matteo Giordano](https://github.com/malteo) for upload and update the package in `AUR`.\n- [Ueno M.](https://github.com/eunos-1128) for upload and update the package in `Homebrew` and `Conda`.\n\nYou can also upload the package yourself to any package manager you use and make [Pull Requests](https://github.com/Lifailon/lazyjournal/pulls).\n\n## Alternatives\n\n- [Lnav](https://github.com/tstack/lnav) - The Logfile Navigator is a log file viewer for the terminal.\n- [TooLong](https://github.com/Textualize/toolong) - A terminal application to view, tail, merge, and search log files.\n- [Dozzle](https://github.com/amir20/dozzle) - A small lightweight application with a web based interface to monitor Docker logs.\n\nIf you like using TUI tools, try [multranslate](https://github.com/Lifailon/multranslate) for translating text in multiple translators simultaneously and LLM, with support for translation history and automatic language detection.\n\n## License\n\nThis project is licensed under the **MIT License**. See the [LICENSE](LICENSE) file for details.\n\nCopyright (C) 2024 Lifailon (Alex Kup)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flifailon%2Flazyjournal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flifailon%2Flazyjournal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flifailon%2Flazyjournal/lists"}