{"id":15176646,"url":"https://github.com/openslo/slogen","last_synced_at":"2026-01-12T01:24:52.759Z","repository":{"id":38085444,"uuid":"414643341","full_name":"OpenSLO/slogen","owner":"OpenSLO","description":"tool to create and manage content for reliability tracking from logs/event data.","archived":false,"fork":false,"pushed_at":"2024-05-30T14:30:22.000Z","size":2880,"stargazers_count":83,"open_issues_count":21,"forks_count":7,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-04-27T11:01:56.414Z","etag":null,"topics":["command-line-tool","golang","openslo","reliability","slo","sumologic","terraform"],"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/OpenSLO.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2021-10-07T14:52:46.000Z","updated_at":"2024-12-13T08:06:35.000Z","dependencies_parsed_at":"2023-02-17T07:46:04.986Z","dependency_job_id":"b01d14f3-7588-4712-b180-4c79ea99ddb0","html_url":"https://github.com/OpenSLO/slogen","commit_stats":{"total_commits":128,"total_committers":6,"mean_commits":"21.333333333333332","dds":0.375,"last_synced_commit":"22a5518c74540e4bf8c7c8b7d29159b4efa027b2"},"previous_names":["sumologic-incubator/slogen","sumologic-labs/slogen"],"tags_count":27,"template":false,"template_full_name":null,"purl":"pkg:github/OpenSLO/slogen","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenSLO%2Fslogen","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenSLO%2Fslogen/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenSLO%2Fslogen/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenSLO%2Fslogen/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OpenSLO","download_url":"https://codeload.github.com/OpenSLO/slogen/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenSLO%2Fslogen/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271230021,"owners_count":24722845,"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","status":"online","status_checked_at":"2025-08-19T02:00:09.176Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["command-line-tool","golang","openslo","reliability","slo","sumologic","terraform"],"created_at":"2024-09-27T13:23:05.907Z","updated_at":"2026-01-12T01:24:52.705Z","avatar_url":"https://github.com/OpenSLO.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"### slogen\n\nCLI tool to generate SLO dashboards, monitors \u0026 SLI data\nfrom [OpenSLO](https://github.com/OpenSLO/OpenSLO#specification) configs. \nThe resources are generated via terraform which can be consumed on its as as well.\n\n\nCurrently supported vendors/data sources.\n\n- Sumologic - more details [here](samples/sumologic/README.md) \n\n![list](misc/sumo-sli-list.gif)\n![panels](misc/sumo-slo-dashboard.png)\n\nA flow graph of `SLO` to `AlertPolicy` to `AlertNotificationTarget` is also generated in the output dir as `slo-dep-graph.png`.\nFlow graphs for sample configs [here](samples/sumologic/v1) (only supported for v1 onward specs).\n\n![dep-graph](misc/samples-flowchart.png)\n\n\n#### Getting the tool\n\n##### install with go1.17 or above as `go install github.com/OpenSLO/slogen@latest`\n\nlatest golang release can be installed by using the directions here : https://github.com/udhos/update-golang#usage.\nAdd `$GOPATH/bin` to your `$PATH`.\n\nIt can be done with\n\n```\nexport PATH=`go env GOPATH`/bin:$PATH\n```\n\nThe pre-compiled binaries for specific platforms are also available on the [release](https://github.com/OpenSLO/slogen/releases) page.\n\n### Using the tool\n\n##### Set the sumologic auth as `ENV` variables as required by the [terraform provider](https://registry.terraform.io/providers/SumoLogic/sumologic/latest/docs#environment-variables):\n\n##### _Note_ : Terraform installation is not required as the tool binary has it embedded as [terraform-exec](https://github.com/hashicorp/terraform-exec)\n\n--- \n\n##### create the yaml config for the SLO. more [samples](samples/sumologic/logs) based on real data.\n\n--- \n\n##### validate the configs as (you can also pass the path to the entire dir to validate the files in it.)\n\n`slogen validate path/to/config`\n\n--- \n\n##### run the tool to generate the terraform files and apply them (you can remove the `--apply` to just generate the files)\n\n`slogen path/to/config --apply`\n\nIf you remove any of the OpenSLO configs, then you should use\n\n`slogen path/to/config --apply --clean`\n\nthe `--clean` option will remove the generated terraform files for which the yaml config no longer exists.\n\n--- \n\n##### running the tool behind a http/https proxy\nset the following env variables in the bash session before running the tool\n\n```shell\nexport HTTP_PROXY=\"http://proxyIp:proxyPort\"\nexport HTTPS_PROXY=\"http://proxyIp:proxyPort\"\n```\n\n##### for further details run `slogen help`\n\n```\nUsage:\nslogen [paths to yaml config]... [flags]\nslogen [command]\n\nExamples:\nslogen service/search.yaml \nslogen ~/team-a/slo/ ~/team-b/slo ~/core/slo/login.yaml \nslogen ~/team-a/slo/ -o team-a/tf\nslogen ~/team-a/slo/ -o team-a/tf --apply --clean \n\nAvailable sub-commands:\nhelp          Help about any command \nlist          utility command to get additional info about your sumo resources e.g.\ndestroy       destroy the content generated from the slogen command, equivalent to 'terraform destroy'\nnew           create a sample config from given profile \nvalidate      config is as per OpesSLO standards and has valid values.\ncompletion    generate the autocompletion script for the specified shell \ndocs          A brief description of your command \n\nFlags:\n-o, --out string        :   output directory where to create the terraform files (default \"tf\")\n-d, --dashboardFolder   :   string output directory where to create the terraform files (default \"slogen-tf-dashboards\")\n-m, --monitorFolder     :   string output directory where to create the terraform files (default \"slogen-tf-monitors\")\n-i, --ignoreErrors      :   whether to continue validation even after encountering errors \n-p, --plan              :   show plan output after generating the terraform config \n-a, --apply             :   apply the generated terraform config as well \n-c, --clean             :   clean the old tf files for which openslo config were not found in the path args \n-h, --help              :   help for slogen\n    --asModule          :   whether to generate the terraform config as a module\n    --useViewHash      :   whether to use descriptive or hashed name for the scheduled views, hashed names ensure data for old view is not used when the query for it changes\n\nUse \"slogen [command] --help\" for more information about a command. Example config with inline comment explaining the\nvarious fields\n\n```\n\n### deleting resources created\n\nrun the below command\n\n`slogen destroy [path to out dir (default to './tf')]`\n\nIt will show the resources that will be deleted and ask for confirmation before deleting them. \n\n\n### sample configs\n- [`openslo/v1`](samples/sumologic/v1)\n- deprecated [`openslo/v1alpha`](samples/sumologic/logs)\n\n\n\n##### Getting connection ID's for alert notification\nCurrently, the sumo UI doesn't provide a way to get the connection id's for alert notification.\nAs a workaround, you can use the following command to get the id list.\n\n```shell\nslogen list -c\n```\n\n### Support for Labels\nSlogen supports `labels` from the OpenSLO config and applies them as tags to the native SLOs created in the vendor environment (Sumologic). In the OpenSLO spec, `metadata.labels` is an optional map of keys to one or more values. Slogen supports only one value per unique key. The first value specified in the list of values will be considered.\n\n### Change Log\n- [Bug fixes in v1.3](CHANGELOG.md)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenslo%2Fslogen","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopenslo%2Fslogen","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenslo%2Fslogen/lists"}