Skip to content

Highly configurable Ansible role to Install and manage Apache Kafka and Apache Zookeeper "from scratch" using Confluent package

License

Notifications You must be signed in to change notification settings

macunha1/ansible-confluent-kafka

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

69 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Confluent Kafka Ansible Role

GitHub Workflow Status

This Ansible Role aims to install and configure Apache Kafka and Apache Zookeeper using the Confluent package.

All configurations can be passed through vars, you can see the list of necessary vars at defaults and customize them as you wish.

Getting Started

Prerequisites

Ansible 2.10+, Python and Pip.

pip install ansible>=2.10.0

After installing Ansible, you MUST install a Java role, JDK is a must-have in your playbook. Kafka needs a JVM to run.

You can see the recommended version here) as well as the supported Java versions and JDK implementations.

Pick your favorite from the list, set a role to install and configure it.

Tests

The test suite is currently executing against Ansible 2.12 (as you can see here), inside Docker containers running Ansible on Python 3, using Open JDK for the sake of testing.

If you are curious about the status, there is a scheduled job that runs every day, take a look at the GitHub Actions build history ;)

For further information on the Docker images being used to run containers on the CI, take a look at docker-ansible

Quickstart

Example playbook

---
- hosts: kafka,zookeeper

  vars:
    local_path: "/tmp"
    confluent_version: "5.4.0"
    confluent_distribution: "confluent-community"
    log_basepath: "/var/log"
    data_basepath: "/var/data"
    initscripts_path: "/usr/sbin"
    conf_dest: "/etc/config"

  roles:
    - macunha1.confluent_kafka

Minimal playbook

---
- hosts: kafka,zookeeper

  roles:
    - macunha1.confluent_kafka

Example inventory

[kafka]
192.168.50.3

[zookeeper]
192.168.50.3

Contribute

PRs Welcome

Feel free to fill an issue containing feature request(s), or (even better) to send me a Pull request, I would be happy to collaborate with you.

If this role didn't work for you, or if you found some bug during the execution, let me know.

About

Highly configurable Ansible role to Install and manage Apache Kafka and Apache Zookeeper "from scratch" using Confluent package

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •