{"id":19865712,"url":"https://github.com/kevincobain2000/gol","last_synced_at":"2025-04-07T19:13:08.065Z","repository":{"id":243663686,"uuid":"811681167","full_name":"kevincobain2000/gol","owner":"kevincobain2000","description":"No you don't need a 64GB RAM and ElasticSearch. An all in One - Dependency free (docker, local, remote) Log Viewer in Browser. Written in GO with God Speed.","archived":false,"fork":false,"pushed_at":"2025-02-15T10:23:09.000Z","size":331,"stargazers_count":86,"open_issues_count":3,"forks_count":10,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-31T18:18:28.321Z","etag":null,"topics":["browser-logging","docker-logs","golang-log","golang-logging","log-management","log-viewer","log-visualization","log-visualizer","logs","remote-log"],"latest_commit_sha":null,"homepage":"https://medium.com/web-developer/logs-viewer-view-real-time-logs-in-your-browser-easily-d532f1000a2b","language":"Astro","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/kevincobain2000.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}},"created_at":"2024-06-07T04:59:15.000Z","updated_at":"2025-03-20T06:22:42.000Z","dependencies_parsed_at":"2024-06-17T12:58:22.680Z","dependency_job_id":"cb39182d-4273-4e44-9085-cbeba88552fc","html_url":"https://github.com/kevincobain2000/gol","commit_stats":{"total_commits":94,"total_committers":1,"mean_commits":94.0,"dds":0.0,"last_synced_commit":"eb70a9668658277ba820ce2c49a0fe4edcba2c2a"},"previous_names":["kevincobain2000/gol"],"tags_count":38,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kevincobain2000%2Fgol","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kevincobain2000%2Fgol/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kevincobain2000%2Fgol/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kevincobain2000%2Fgol/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kevincobain2000","download_url":"https://codeload.github.com/kevincobain2000/gol/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247713258,"owners_count":20983683,"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":["browser-logging","docker-logs","golang-log","golang-logging","log-management","log-viewer","log-visualization","log-visualizer","logs","remote-log"],"created_at":"2024-11-12T15:23:51.745Z","updated_at":"2025-04-07T19:13:07.752Z","avatar_url":"https://github.com/kevincobain2000.png","language":"Astro","funding_links":[],"categories":["Astro"],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/kevincobain2000/gol\"\u003e\n    \u003cimg alt=\"gol\" src=\"https://imgur.com/sktoYPP.png\" width=\"120\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003ch1 align=\"center\"\u003e\n  Logs Viewer\n\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n  View realtime logs in your fav browser\u003cbr\u003e\n  Advanced regex search\u003cbr\u003e\n  Low Mem Footprint\u003cbr\u003e\n  Single binary\n\u003c/p\u003e\n\n\u003ch3 align=\"center\"\u003e\n  Supports\n\u003c/h3\u003e\n\n\u003cp align=\"center\"\u003e\n  Docker Container logs from path\u003cbr\u003e\n  Docker Container logs\u003cbr\u003e\n  SSH remote logs\u003cbr\u003e\n  STDIN logs\u003cbr\u003e\n  Local logs\u003cbr\u003e\n  Tar logs\u003cbr\u003e\n\u003c/p\u003e\n\n- **Quick Setup:** One command to install and run.\n\n- **Hassle Free:** Doesn't require elastic search or other shebang.\n\n- **Platform:** Supports (arm64, arch64, Mac, Mac M1, Ubuntu and Windows).\n\n- **Flexible:** View docker logs, remote logs over ssh, files on disk and piped inputs in browser.\n\n- **Intelligent** Smartly judges log level, and dates.\n\n- **Search** Fast search with regex.\n\n- **Realtime** Tail logs in real time in browser.\n\n- **Log Rotation** Supports log rotation and watch for new log files.\n\n- **Embed in GO** Easily embed in your existing Go app.\n\n\u003ch1 align=\"center\"\u003e\n  View in Browser\n\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n Intuitive UI to view logs in browser\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/kevincobain2000/gol\"\u003e\n    \u003cimg alt=\"gol\" src=\"https://imgur.com/fBK0hGa.png\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n### Install using curl\n\nUse this method if go is not installed on your server\n\n```bash\ncurl -sL https://raw.githubusercontent.com/kevincobain2000/gol/master/install.sh | sh\n```\n\n## Examples\n\n### CLI - Basic Example\n\n```sh\n# run in current directory for pattern\ngol \"*log\" \"access/*log.tar.gz\"\n```\n\n### CLI - Advanced Examples\n\nAll patterns work in combination with each other.\n\n```sh\n# search using pipe and file patterns\ndemsg | gol -f=\"/var/log/*.log\"\n\n# over ssh\n# port optional (default 22), password optional (default ''), private_key optional (default $HOME/.ssh/id_rsa)\ngol -s=\"user@host[:port] [password=/path/to/password] [private_key=/path/to/key] /app/*logs\"\n\n# Docker all container logs\ngol -d=\"\"\n\n# Docker specific container logs\ngol -d=\"container-id\"\n\n# Docker specific path on a container\ngol -d=\"container-id /app/logs.log\"\n\n# All patterns combined\ngol -d=\"container-id\" \\\n    -d=\"container-id /app/logs.log\" \\\n    -s=\"user@host[:port] [password=/path/to/password] [private_key=/path/to/key] /app/*logs\" \\\n    -f=\"/var/log/*.log\"\n```\n\n### Embed in GO\n\nIf you don't want to use CLI to have seperate port and want to integrate within your existing Go app.\n\n\n```go\nimport (\n\t\"fmt\"\n\t\"net/http\"\n\n\t\"github.com/kevincobain2000/gol\"\n)\n\nfunc main() {\n    // init with options of file path you want to watch\n    g := gol.NewGol(func(o *gol.GolOptions) error {\n        o.FilePaths = []string{\"*.log\"}\n        return nil\n    })\n\n    // register following two routes\n    http.HandleFunc(\"/gol/api\", g.Adapter(g.NewAPIHandler().Get))\n    http.HandleFunc(\"/gol\", g.Adapter(g.NewAssetsHandler().Get))\n\n    // start server as usual\n    http.ListenAndServe(\"localhost:8080\", nil)\n}\n```\n\n## CHANGE LOG\n\n- **v1.0.0** - Initial release.\n- **v1.0.3** - Multiple file patterns, and pipe input support.\n- **v1.0.4** - Support os.Args for quick view.\n- **v1.0.5** - Support ssh logs.\n- **v1.0.6** - UI shows grouped output.\n- **v1.0.7** - Support docker logs.\n- **v1.0.14** - Sleak UI changes and support dates.\n- **v1.0.17** - Support both ignore and include patterns.\n- **v1.0.21** - Better logging.\n- **v1.0.22** - Support UA.\n- **v1.0.24** - Dropdown on files.\n- **v1.0.25** - Searchable files.\n- **v1.1.0** - Embed in GO, buggy.\n- **v1.1.1** - Embed in GO, stable.\n- **v1.1.2** - Go VUP\n- **v1.1.3** - Node VUP and debounce for better performance.\n\n## Limitations\n\n- **Docker Logs:** Only supports logs from containers running on the same machine.\n- **fmt, stdout:** For embedded use, fmt and stdout logs are not intercepted.\n\n  **Tip:** If you want to capture, then run your app by piping output as `./app \u003e\u003e logs.log`.\n\n\n## Development Notes\n\n```sh\n# Get some fake logs\nmkdir -p testdata\nwhile true; do date \u003e\u003e testdata/test.log; sleep 1; done\n\n# Start the API\ncd frontend\ngo run main.go --cors=4321 --open=false -f=\"../testdata/*log\"\n# API development on http://localhost:3003/api\n\n# Start the frontend\nnpm install\nnpm run dev\n# Frontend development on http://localhost:4321/\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkevincobain2000%2Fgol","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkevincobain2000%2Fgol","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkevincobain2000%2Fgol/lists"}