salt-kafka


Namesalt-kafka JSON
Version 0.2.0 PyPI version JSON
download
home_pageNone
SummaryManage Kafka clusters with Salt
upload_time2025-07-14 08:00:55
maintainerNone
docs_urlNone
authorNone
requires_python>=3.10
licenseNone
keywords kafka salt
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # salt-kafka

Kafka tools for Salt

[![PyPI - Version](https://img.shields.io/pypi/v/salt-kafka)](https://pypi.org/project/salt-kafka/)
[![Gitea Stars](https://img.shields.io/gitea/stars/kfdm/salt-kafka?gitea_url=https://codeberg.org)](https://codeberg.org/kfdm/salt-kafka)

## Installation

Can be installed via `pip` or the Pip version distributed in Salt onedir installs.
Salt extensions need to be installed to any `salt-minion` where they may run.

```shell
# Example for Salt onedir
/opt/saltstack/salt/salt-pip install salt-kafka

# Can be installed via Salt commands
salt '*' pip.install salt-kafka
```

or Via a salt state

```yaml
salt-minion:
  service.running:
    - enable: true
  # Install any OS requirements
  pkg.installed:
    - aggregate: True
    - pkgs:
        - python3-docker
        - python3-setproctitle
  # Install any pip packages
  pip.installed:
    - pkgs:
        - salt-kafka
```

## Engine

`kafka_consumer` can be used to map Kafka topics to a Salt topic to be used in automation.

```yaml
# From Salt Master config

engines:
  - kafka_consumer:
      broker: kafka.example.com:9094
      subscribe:
        # Format is <kafka-topic> / <salt-topic>
        push-repo: kafka/repo
        push-package: kafka/container
```

## States

```yaml
# Example minion config
kafka.bootstrap.servers: "kafka.example.com:9094"
```

```yaml
# Example kafka.sls
my-topic:
    kafka.present:
        - config:
              cleanup.policy: delete
              retention.ms: {{salt['kafka.timedelta_ms']('2d')}}
              retention.bytes: {{ "1GB" | human_to_bytes }}

missing-topic:
    kafka.absent: []
```

See the Upstream Kafka documentation at <http://kafka.apache.org/documentation.html#topicconfigs> for valid config options.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "salt-kafka",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": null,
    "keywords": "kafka, salt",
    "author": null,
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/c4/b3/4ecd42bafc0f94f08659306ae1c1234c01fdcbed06de481565cb6508e3e4/salt_kafka-0.2.0.tar.gz",
    "platform": null,
    "description": "# salt-kafka\n\nKafka tools for Salt\n\n[![PyPI - Version](https://img.shields.io/pypi/v/salt-kafka)](https://pypi.org/project/salt-kafka/)\n[![Gitea Stars](https://img.shields.io/gitea/stars/kfdm/salt-kafka?gitea_url=https://codeberg.org)](https://codeberg.org/kfdm/salt-kafka)\n\n## Installation\n\nCan be installed via `pip` or the Pip version distributed in Salt onedir installs.\nSalt extensions need to be installed to any `salt-minion` where they may run.\n\n```shell\n# Example for Salt onedir\n/opt/saltstack/salt/salt-pip install salt-kafka\n\n# Can be installed via Salt commands\nsalt '*' pip.install salt-kafka\n```\n\nor Via a salt state\n\n```yaml\nsalt-minion:\n  service.running:\n    - enable: true\n  # Install any OS requirements\n  pkg.installed:\n    - aggregate: True\n    - pkgs:\n        - python3-docker\n        - python3-setproctitle\n  # Install any pip packages\n  pip.installed:\n    - pkgs:\n        - salt-kafka\n```\n\n## Engine\n\n`kafka_consumer` can be used to map Kafka topics to a Salt topic to be used in automation.\n\n```yaml\n# From Salt Master config\n\nengines:\n  - kafka_consumer:\n      broker: kafka.example.com:9094\n      subscribe:\n        # Format is <kafka-topic> / <salt-topic>\n        push-repo: kafka/repo\n        push-package: kafka/container\n```\n\n## States\n\n```yaml\n# Example minion config\nkafka.bootstrap.servers: \"kafka.example.com:9094\"\n```\n\n```yaml\n# Example kafka.sls\nmy-topic:\n    kafka.present:\n        - config:\n              cleanup.policy: delete\n              retention.ms: {{salt['kafka.timedelta_ms']('2d')}}\n              retention.bytes: {{ \"1GB\" | human_to_bytes }}\n\nmissing-topic:\n    kafka.absent: []\n```\n\nSee the Upstream Kafka documentation at <http://kafka.apache.org/documentation.html#topicconfigs> for valid config options.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Manage Kafka clusters with Salt",
    "version": "0.2.0",
    "project_urls": {
        "source": "https://codeberg.org/kfdm/salt-kafka"
    },
    "split_keywords": [
        "kafka",
        " salt"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "7d36cd371b69093350ddeeb6faea4a3de45043964659bf17515504b5e093deb0",
                "md5": "6ba6e128b0447c8fb160c3c4a034fab2",
                "sha256": "cc596c19080eb458918458c780629105bed772663f6bd6253f7e6da34273d7bb"
            },
            "downloads": -1,
            "filename": "salt_kafka-0.2.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "6ba6e128b0447c8fb160c3c4a034fab2",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 7942,
            "upload_time": "2025-07-14T08:00:53",
            "upload_time_iso_8601": "2025-07-14T08:00:53.961793Z",
            "url": "https://files.pythonhosted.org/packages/7d/36/cd371b69093350ddeeb6faea4a3de45043964659bf17515504b5e093deb0/salt_kafka-0.2.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "c4b34ecd42bafc0f94f08659306ae1c1234c01fdcbed06de481565cb6508e3e4",
                "md5": "3f2d013eaf16064b6834891441e8cf2d",
                "sha256": "e554528b455309e2cd68cfed22c63553fae142ac712fa6ee99feca9ccc50eef7"
            },
            "downloads": -1,
            "filename": "salt_kafka-0.2.0.tar.gz",
            "has_sig": false,
            "md5_digest": "3f2d013eaf16064b6834891441e8cf2d",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 5435,
            "upload_time": "2025-07-14T08:00:55",
            "upload_time_iso_8601": "2025-07-14T08:00:55.105246Z",
            "url": "https://files.pythonhosted.org/packages/c4/b3/4ecd42bafc0f94f08659306ae1c1234c01fdcbed06de481565cb6508e3e4/salt_kafka-0.2.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-14 08:00:55",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": true,
    "codeberg_user": "kfdm",
    "codeberg_project": "salt-kafka",
    "lcname": "salt-kafka"
}
        
Elapsed time: 0.63205s