{"id":22598956,"url":"https://github.com/projectsveltos/event-manager","last_synced_at":"2025-04-11T01:22:00.492Z","repository":{"id":142544131,"uuid":"609300387","full_name":"projectsveltos/event-manager","owner":"projectsveltos","description":"Watches for events in managed clusters and generates ClusterProfiles on the fly","archived":false,"fork":false,"pushed_at":"2024-07-12T14:56:06.000Z","size":966,"stargazers_count":3,"open_issues_count":1,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-07-13T11:33:07.686Z","etag":null,"topics":["addon","event-driven","kubernetes","multi-tenancy"],"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/projectsveltos.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2023-03-03T20:08:21.000Z","updated_at":"2024-07-15T23:04:50.117Z","dependencies_parsed_at":"2024-03-26T12:30:57.043Z","dependency_job_id":"befa144b-730b-4adc-9c32-9f05553232b3","html_url":"https://github.com/projectsveltos/event-manager","commit_stats":null,"previous_names":[],"tags_count":41,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/projectsveltos%2Fevent-manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/projectsveltos%2Fevent-manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/projectsveltos%2Fevent-manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/projectsveltos%2Fevent-manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/projectsveltos","download_url":"https://codeload.github.com/projectsveltos/event-manager/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248323465,"owners_count":21084510,"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":["addon","event-driven","kubernetes","multi-tenancy"],"created_at":"2024-12-08T11:07:35.389Z","updated_at":"2025-04-11T01:22:00.478Z","avatar_url":"https://github.com/projectsveltos.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![CI](https://github.com/projectsveltos/event-manager/actions/workflows/main.yaml/badge.svg)](https://github.com/projectsveltos/event-manager/actions)\n[![Go Report Card](https://goreportcard.com/badge/github.com/projectsveltos/event-manager)](https://goreportcard.com/report/github.com/projectsveltos/event-manager)\n[![Slack](https://img.shields.io/badge/join%20slack-%23projectsveltos-brighteen)](https://join.slack.com/t/projectsveltos/shared_invite/zt-1hraownbr-W8NTs6LTimxLPB8Erj8Q6Q)\n[![License](https://img.shields.io/badge/license-Apache-blue.svg)](LICENSE)\n[![Twitter Follow](https://img.shields.io/twitter/follow/projectsveltos?style=social)](https://twitter.com/projectsveltos)\n\n# Sveltos\n\n\u003cimg src=\"https://raw.githubusercontent.com/projectsveltos/sveltos/main/docs/assets/logo.png\" width=\"200\"\u003e\n\nPlease refere to sveltos [documentation](https://projectsveltos.github.io/sveltos/).\n\n## Event driven framework in action\n\nSveltos supports an event-driven add-on deployment oworkflow:\n\n1. define what an event is;\n2. select on which clusters;\n3. define which add-ons to deploy when event happens.\n\n[EventSource](https://github.com/projectsveltos/libsveltos/blob/main/api/v1beta1/eventsource_type.go) is the CRD introduced to define an event.\n\nSveltos supports custom events written in [Lua](https://www.lua.org/).\n\nFollowing EventSource instance define an __event__ as a creation/deletion of a Service with label *sveltos: fv*.\n\n```yaml\napiVersion: lib.projectsveltos.io/v1beta1\nkind: EventSource\nmetadata:\n name: sveltos-service\nspec:\n collectResources: true\n group: \"\"\n version: \"v1\"\n kind: \"Service\"\n labelsFilters:\n - key: sveltos\n   operation: Equal\n   value: fv\n```\n\nSveltos supports custom events written in [Lua](https://www.lua.org/). \nFollowing EventSource instance again defines an Event as the creation/deletion of a Service with label *sveltos: fv* but using a Lua script. \n\n```yaml\napiVersion: lib.projectsveltos.io/v1beta1\nkind: EventSource\nmetadata:\n name: sveltos-service\nspec:\n collectResources: true\n group: \"\"\n version: \"v1\"\n kind: \"Service\"\n script: |\n  function evaluate()\n    hs = {}\n    hs.matching = false\n    hs.message = \"\"\n    if obj.metadata.labels ~= nil then\n      for key, value in pairs(obj.metadata.labels) do\n        if key == \"sveltos\" then\n          if value == \"fv\" then\n            hs.matching = true\n          end\n        end\n      end\n    end\n    return hs\n  end\n```\n\n[EventTrigger](https://github.com/projectsveltos/libsveltos/blob/main/api/v1beta1/eventtrigger_type.go) is the CRD introduced to define what add-ons to deploy when an event happens.\n\n![Sveltos Event Driven Framework](https://github.com/projectsveltos/demos/blob/main//event-driven/event_driven_framework.gif)\n\nEvent manager is a Sveltos micro service in charge of deploying add-ons when certain events happen in managed clusters.\n\n## Contributing \n\n❤️ Your contributions are always welcome! If you want to contribute, have questions, noticed any bug or want to get the latest project news, you can connect with us in the following ways:\n\n1. Open a bug/feature enhancement on github [![contributions welcome](https://img.shields.io/badge/contributions-welcome-brightgreen.svg?style=flat)](https://github.com/projectsveltos/addon-controller/issues)\n2. Chat with us on the Slack in the #projectsveltos channel [![Slack](https://img.shields.io/badge/join%20slack-%23projectsveltos-brighteen)](https://join.slack.com/t/projectsveltos/shared_invite/zt-1hraownbr-W8NTs6LTimxLPB8Erj8Q6Q)\n3. [Contact Us](mailto:support@projectsveltos.io)\n\n## License\n\nCopyright 2022.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprojectsveltos%2Fevent-manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprojectsveltos%2Fevent-manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprojectsveltos%2Fevent-manager/lists"}