{"id":19277668,"url":"https://github.com/observiq/stanza","last_synced_at":"2025-05-15T18:09:34.678Z","repository":{"id":37036224,"uuid":"277620818","full_name":"observIQ/stanza","owner":"observIQ","description":"Fast and lightweight log transport and processing.","archived":false,"fork":false,"pushed_at":"2024-12-11T23:33:08.000Z","size":4821,"stargazers_count":183,"open_issues_count":42,"forks_count":22,"subscribers_count":13,"default_branch":"main","last_synced_at":"2025-04-17T16:56:24.659Z","etag":null,"topics":["golang","log-parsing","logging","observability","telemetry"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/observIQ.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":"GOVERNANCE.md","roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-07-06T18:37:56.000Z","updated_at":"2025-03-27T06:37:08.000Z","dependencies_parsed_at":"2023-12-18T16:03:19.665Z","dependency_job_id":"6e378b14-ce02-46f4-8469-812d3585f8d5","html_url":"https://github.com/observIQ/stanza","commit_stats":null,"previous_names":["observiq/carbon"],"tags_count":115,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/observIQ%2Fstanza","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/observIQ%2Fstanza/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/observIQ%2Fstanza/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/observIQ%2Fstanza/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/observIQ","download_url":"https://codeload.github.com/observIQ/stanza/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254394722,"owners_count":22063984,"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":["golang","log-parsing","logging","observability","telemetry"],"created_at":"2024-11-09T21:06:35.488Z","updated_at":"2025-05-15T18:09:34.634Z","avatar_url":"https://github.com/observIQ.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\u003cimg src=\"docs/images/logo_small.png?raw=true\"\u003e\u003c/p\u003e\n\n\u003ccenter\u003e\n\n[![Action Status](https://github.com/observIQ/stanza/workflows/Build/badge.svg)](https://github.com/observIQ/stanza/actions)\n[![Action Test Status](https://github.com/observIQ/stanza/workflows/Tests/badge.svg)](https://github.com/observIQ/stanza/actions)\n[![codecov](https://codecov.io/gh/observIQ/stanza/branch/master/graph/badge.svg)](https://codecov.io/gh/observIQ/stanza)\n[![Go Report Card](https://goreportcard.com/badge/github.com/observIQ/stanza)](https://goreportcard.com/report/github.com/observIQ/stanza)\n[![License](https://github.com/observIQ/stanza/workflows/license/badge.svg)](https://github.com/observIQ/stanza/license)\n[![Gosec](https://github.com/observIQ/stanza/actions/workflows/gosec.yml/badge.svg)](https://github.com/observIQ/stanza/actions/workflows/gosec.yml)\n\n\u003c/center\u003e\n\n# About Stanza\n\nStanza is a fast and lightweight log transport and processing agent. It's designed as a modern replacement for Fluentd, Fluent Bit, and Logstash and can run as a standalone agent on all major operating systems. Stanza is also highly integrated to perform seamlessly with the applications in Google Cloud Platform (GCP) based production environments.\n\n## OpenTelemetry\n\nStanza has been contributed to the [OpenTelemetry](https://opentelemetry.io/) project and will be intergrated into the [OpenTelemetry collector](https://github.com/open-telemetry/opentelemetry-collector). \n\n# Features\n\n- Flexible\n    - Supports many different input types such as file, journald, windows events, tcp / udp, and external APIs (cloudwatch, azure log analytics) as well as parsing with json and regex.\n    - Easily extended by writing an \"operator\" or \"plugin\" which is just a unit of code that performs a task such as reading data from a source, parsing data, or shipping data.\n- Pre-built Plugins\n    - Over 80 Plugins have been pre-built and are ready to be configured.\n- Lightweight with low resource consumption\n    - Uses next to no resource while idling. It does not pollute the system with tons of clutter, it exists strictly in /opt/observiq/stanza with just a few files.\n- Written in pure Go\n    - Everything is self contained into a single binary, there are no external dependencies.\n- High Performance\n    - Stanza is lightweight, blazing-fast, and designed to scale.\n\n## Supported [Plugins](https://github.com/observIQ/stanza-plugins)\n\nUtilize Plugins to get up and running quickly. Here's a quick list of Stanza's most popular plugins:\n\n\u003cp align=\"center\"\u003e\u003cimg src=\"docs/images/stanza_plugins.png?raw=true\"\u003e\u003c/p\u003e\n\n These are many of the Plugins supported by Stanza, with more being developed all the time. View a full list of Plugins [here](https://github.com/observIQ/stanza-plugins/tree/main/plugins).\n\n## Supported Operating Systems\n\n### Windows\n- 2012\n- 2012 r2\n- 2016\n- 2019\n- 2022\n\n### Linux\n- Ubuntu 16.04, 18.04, 20.04\n- Debian 9, 10, 11\n- Alma, Rocky 8\n- Red Hat 7, 8\n- Suse 12, 15\n- CentOS 7, 8 Stream\n\n### MacOS\n- 12 (Monterey)\n- 11 (Big Sur)\n- 10.15 (Catalina)\n- 10.14 (Mojave)\n\n# Quick Start\n\n## Installation\n\n### Linux Package Manager\n\nLinux packages are available for the following Linux Distributions:\n- RHEL / CentOS 7 and 8\n- Oracle Linux 7 and 8\n- Alma, Rocky Linux\n- Fedora 30 and newer\n- Debian 9 and newer\n- Ubuntu LTS 16.04 and newer\n\nOnce installed, Stanza will be running under a systemd service named `stanza` as the user `stanza`.\n\n#### RPM Install\n\nOn Red Hat based platforms, Stanza can be installed with:\n```bash\nsudo dnf install https://github.com/observIQ/stanza/releases/download/v1.6.1/stanza_1.6.1_linux_amd64.rpm\nsudo systemctl enable --now stanza\n```\n\nOn RHEL / Centos 7, use `yum` instead of `dns`.\n\nOn Suse based platforms, Stanza can be installed with:\n```bash\nsudo zypper install https://github.com/observIQ/stanza/releases/download/v1.6.1/stanza_1.6.1_linux_amd64.rpm\nsudo systemctl enable --now stanza\n```\n\nBe sure to replace the URL with the version you require. You can find Stanza versions [here](https://github.com/observIQ/stanza/releases).\n\n#### DEB Install\n\nOn Debian / Ubuntu based platforms, Stanza can be installed with:\n\n```bash\ncurl -L -o stanza.deb https://github.com/observIQ/stanza/releases/download/v1.6.1/stanza_1.6.1_linux_amd64.deb\nsudo apt-get install -f ./stanza.deb\nsudo systemctl enable --now stanza\n```\n\n#### Changing the Runtime User\n\nSometimes it may be nessisary to have Stanza run as `root`. This can be\naccomplished by creating a systemd override.\n\nRun `sudo systemctl edit stanza` and paste:\n```\n[Service]\nUser=root\nGroup=root\n```\n\nRestart Stanza: `sudo systemctl restart stanza`.\n\n### Linux / macOS Script\n\n- Single command install, requires the `curl` command\n- Stanza will automatically be running as a service\n- On Linux, Stanza will be running as the `root` user. On Macos, Stanza will be running as your current user.\n- `sudo` is always required for Linux installations while macOS requires it if the invoking user does not have write permissions to `/usr/local/bin`.\n\n```shell\nsh -c \"$(curl -fsSlL https://github.com/observiq/stanza/releases/latest/download/unix-install.sh)\" unix-install.sh\n```\n\n### Windows Script\n\n```pwsh\n[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 ; Invoke-Expression ((New-Object net.webclient).DownloadString('https://github.com/observiq/stanza/releases/latest/download/windows-install.ps1')); Log-Agent-Install\n```\n\n### Kubernetes\n\nTo deploy Stanza to Kubernetes, AKS, EKS, GKE or Openshift check out the installation guides [here](/docs/examples/k8s).\n\n## Configuration\n\nTo get started navigate to the `config.yaml` file in the Stanza install directory, located in the following locations by default:\n\n- Linux: `/opt/observiq/stanza`  \n- MacOS: `/Users/\u003cuser\u003e/observiq/stanza`  \n- Windows: `C:\\observiq\\stanza`\n\nYou can utilize [operators](/docs/operators/README.md) and [plugins](/docs/plugins.md) in a pipeline to easily configure Stanza to ship logs to your target destination.\n\nStanza also offers several outputs to be configured for sending data, including: \n\n- [Stdout](/docs/operators/stdout.md)\n- [File](/docs/operators/file_output.md)\n- [Google Cloud Logging](/docs/operators/google_cloud_output.md)\n\nIn the below examples, Stanza is configured to ship logs to Google Cloud logging using the file_input operator, and the MySQL plugin. You will need to have a `credentials.json` for your GCP environment which can be generated by following Google's documentation [here](https://cloud.google.com/iam/docs/creating-managing-service-account-keys).\n\n### Operators\nThis `config.yaml` collects logs from a file and sends them to Google Cloud. A full list of available operators can be found [here](/docs/operators/README.md).\n\n```yaml\npipeline:\n  # An example input that monitors the contents of a file.\n  # For more info: https://github.com/observIQ/stanza/blob/master/docs/operators/file_input.md\n  - type: file_input\n    include:\n    - /sample/file/path.log\n\n  # An example output that sends captured logs to Google Cloud.\n  # For more info: https://github.com/observIQ/stanza/blob/master/docs/operators/google_cloud_output.md\n  - type: google_cloud_output\n    credentials_file: /tmp/credentials.json\n```\n\n### Plugins\nThis `config.yaml` collects logs from MySQL via a plugin and sends them to Google Cloud. By default, MySQL plugin collects general, slow query, and error logs. More details of the MySQL plugin can be viewed [here](https://github.com/observIQ/stanza-plugins/blob/main/plugins/mysql.yaml). A full list of available plugins can be found [here](https://github.com/observIQ/stanza-plugins/blob/main/plugins/).\n\n```yaml\npipeline:\n  # An example input that configures a MySQL plugin.\n  # For more info: https://github.com/observIQ/stanza/blob/master/docs/plugins.md\n  - type: mysql\n    enable_general_log: true\n    general_log_path: \"/var/log/mysql/general.log\"\n\n  # An example output that sends captured logs to Google Cloud.\n  # For more info: https://github.com/observIQ/stanza/blob/master/docs/operators/google_cloud_output.md\n  - type: google_cloud_output\n    credentials_file: /tmp/credentials.json\n```\n\nThat's it! Logs should be streaming to Google Cloud.\n\nFor more details on installation and configuration, check out our full [Install Guide](/docs/README.md)!\n\n### Common Scenarios\n\nTo see specific examples of Stanza configuration, check out the [scenarios](/docs/examples/scenarios). Below are some of our more popular scenarios:\n\n- [Syslog](/docs/examples/scenarios/syslog.md)\n- [MySQL](/docs/examples/scenarios/mysql.md)\n- [Windows Events](/docs/examples/scenarios/windows_events.md)\n- [File](/docs/examples/scenarios/file.md)\n- [Custom Parsing](/docs/examples/scenarios/custom_parsing.md)\n\n# Community\n\nStanza is an open source project. If you'd like to contribute, take a look at our [contribution guidelines](/CONTRIBUTING.md) and [developer guide](/docs/development.md). We look forward to building with you.\n\n## Code of Conduct\n\nStanza follows the [CNCF Code of Conduct](https://github.com/cncf/foundation/blob/master/code-of-conduct.md). Please report violations of the Code of Conduct to any or all [maintainers](MAINTAINERS.md).\n\n\n# Other questions?\n\nCheck out our [FAQ](/docs/faq.md), send us an [email](mailto:support.stanza@observiq.com), or open an issue with your question. We'd love to hear from you!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fobserviq%2Fstanza","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fobserviq%2Fstanza","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fobserviq%2Fstanza/lists"}