{"id":14981247,"url":"https://github.com/lkubb/salt-elastic-formula","last_synced_at":"2026-02-05T00:35:30.771Z","repository":{"id":134852479,"uuid":"587678411","full_name":"lkubb/salt-elastic-formula","owner":"lkubb","description":"Manage an Elastic stack with Salt.","archived":false,"fork":false,"pushed_at":"2024-11-13T23:05:01.000Z","size":266,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-10T03:52:08.872Z","etag":null,"topics":["devops","elasticsearch","elasticstack","salt","salt-formula","saltstack","saltstack-formula"],"latest_commit_sha":null,"homepage":"","language":"SaltStack","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lkubb.png","metadata":{"files":{"readme":"docs/README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"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-01-11T10:20:31.000Z","updated_at":"2024-11-13T23:05:04.000Z","dependencies_parsed_at":"2024-02-17T19:26:08.698Z","dependency_job_id":"3d50dfa9-17f5-4dbe-b3d7-0e85cc7af1db","html_url":"https://github.com/lkubb/salt-elastic-formula","commit_stats":{"total_commits":18,"total_committers":1,"mean_commits":18.0,"dds":0.0,"last_synced_commit":"d26510025e5eaab89262c51a0b71cdfbf8eb9b69"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/lkubb/salt-elastic-formula","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-elastic-formula","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-elastic-formula/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-elastic-formula/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-elastic-formula/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lkubb","download_url":"https://codeload.github.com/lkubb/salt-elastic-formula/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lkubb%2Fsalt-elastic-formula/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29103414,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-04T22:44:52.815Z","status":"ssl_error","status_checked_at":"2026-02-04T22:44:16.428Z","response_time":62,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["devops","elasticsearch","elasticstack","salt","salt-formula","saltstack","saltstack-formula"],"created_at":"2024-09-24T14:03:12.368Z","updated_at":"2026-02-05T00:35:30.752Z","avatar_url":"https://github.com/lkubb.png","language":"SaltStack","funding_links":[],"categories":[],"sub_categories":[],"readme":".. _readme:\n\nElastic Formula\n===============\n\n|img_sr| |img_pc|\n\n.. |img_sr| image:: https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg\n   :alt: Semantic Release\n   :scale: 100%\n   :target: https://github.com/semantic-release/semantic-release\n.. |img_pc| image:: https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit\u0026logoColor=white\n   :alt: pre-commit\n   :scale: 100%\n   :target: https://github.com/pre-commit/pre-commit\n\nManage an Elastic stack with Salt.\n\n.. contents:: **Table of Contents**\n   :depth: 1\n\nGeneral notes\n-------------\n\nSee the full `SaltStack Formulas installation and usage instructions\n\u003chttps://docs.saltproject.io/en/latest/topics/development/conventions/formulas.html\u003e`_.\n\nIf you are interested in writing or contributing to formulas, please pay attention to the `Writing Formula Section\n\u003chttps://docs.saltproject.io/en/latest/topics/development/conventions/formulas.html#writing-formulas\u003e`_.\n\nIf you want to use this formula, please pay attention to the ``FORMULA`` file and/or ``git tag``,\nwhich contains the currently released version. This formula is versioned according to `Semantic Versioning \u003chttp://semver.org/\u003e`_.\n\nSee `Formula Versioning Section \u003chttps://docs.saltproject.io/en/latest/topics/development/conventions/formulas.html#versioning\u003e`_ for more details.\n\nIf you need (non-default) configuration, please refer to:\n\n- `how to configure the formula with map.jinja \u003cmap.jinja.rst\u003e`_\n- the ``pillar.example`` file\n- the `Special notes`_ section\n\nSpecial notes\n-------------\n* This formula is written with a Vault database secret engine in mind. Note that the Vault integration currently requires my rewritten `Vault modules \u003chttps://github.com/lkubb/salt-vault-formula\u003e`_, which might become available in Salt at some point.\n* The certificate management requires my rewritten `x509 modules \u003chttps://github.com/lkubb/salt-pca-formula\u003e`_ (for ``pkcs12``), which are available from Salt v3006 onwards as ``x509_v2``.\n* All of the ``*beat`` and ``logstash`` states are boilerplate at the moment.\n* The tests only serve an esthetical purpose currently (not implemented).\n\nConfiguration\n-------------\nAn example pillar is provided, please see `pillar.example`. Note that you do not need to specify everything by pillar. Often, it's much easier and less resource-heavy to use the ``parameters/\u003cgrain\u003e/\u003cvalue\u003e.yaml`` files for non-sensitive settings. The underlying logic is explained in `map.jinja`.\n\n\nAvailable states\n----------------\n\nThe following states are found in this formula:\n\n.. contents::\n   :local:\n\n\n``elastic``\n^^^^^^^^^^^\nInstalls the Elastic repo.\n\nDoes not install/configure/start any packages/services.\n\n\n``elastic.repo``\n^^^^^^^^^^^^^^^^\n\n\n\n``elastic.auditbeat``\n^^^^^^^^^^^^^^^^^^^^^\nInstalls, configures and starts Auditbeat.\n\n\n``elastic.auditbeat.config``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.auditbeat.package``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.auditbeat.service``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.elasticsearch``\n^^^^^^^^^^^^^^^^^^^^^^^^^\n*Meta-state*.\nManages the lifecycle of an Elasticsearch node/cluster\nwith integration to the Vault database secret engine.\n\nIncludes all states for ES, with the exception of\n`elastic.elasticsearch.vault_setup`_.\n\n\n``elastic.elasticsearch.auth``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nTakes care of managing ES users and groups and\nmanaging the Vault database secret engine connection.\nAlso, optionally resets the bootstrap password.\nDepends on `elastic.elasticsearch.service`_.\n\n\n``elastic.elasticsearch.bootstrap_pass``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nEnsures a known bootstrap password is set in order to\nbe able to manage the initial configuration non-interactively.\nDepends on `elastic.elasticsearch.config`_.\n\n\n``elastic.elasticsearch.certs``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nGenerates and manages certificates + keys for the HTTP and transport layers,\nincluding trusted CA certificates for Elasticsearch.\nNote that generally, it's advisable to setup a CA minion. See the\n``x509`` (``x509_v2``) module docs for details.\nDepends on `elastic.elasticsearch.package`_.\n\n\n``elastic.elasticsearch.config``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nManages ES and JVM configuration.\nDepends on `elastic.elasticsearch.package`_.\n\n\n``elastic.elasticsearch.package``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nInstalls Elasticsearch only.\nDepends on `elastic.repo`_.\n\n\n``elastic.elasticsearch.service``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nEnables and (re-)starts Elasticsearch.\nDepends on `elastic.elasticsearch.config`_, `elastic.elasticsearch.certs`_\nand `elastic.elasticsearch.bootstrap_pass`_\n\n\n``elastic.elasticsearch.vault_roles``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nManages Vault database secret engine roles.\nDepends on `elastic.elasticsearch.auth`_ (for managing\nthe allowed roles on the connection).\n\n\n``elastic.elasticsearch.vault_setup``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nThis should be targeted to your Vault minion(s), not the Elasticsearch one(s).\nGenerates and manages ES client certificates for Vault since\nthe ES database plugin currently does not allow to\npass those in via the REST API.\n\n\n``elastic.filebeat``\n^^^^^^^^^^^^^^^^^^^^\nInstalls, configures and starts Filebeat.\n\n\n``elastic.filebeat.config``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.filebeat.package``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.filebeat.service``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.functionbeat``\n^^^^^^^^^^^^^^^^^^^^^^^^\nInstalls, configures and starts Functionbeat.\n\n\n``elastic.functionbeat.config``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.functionbeat.package``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.functionbeat.service``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.heartbeat``\n^^^^^^^^^^^^^^^^^^^^^\nInstalls, configures and starts Heartbeat.\n\n\n``elastic.heartbeat.config``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.heartbeat.package``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.heartbeat.service``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.kibana``\n^^^^^^^^^^^^^^^^^^\nInstalls, configures and starts Kibana, including\ngenerating client certificates and requesting credentials\nfrom Vault.\n\n\n``elastic.kibana.auth``\n^^^^^^^^^^^^^^^^^^^^^^^\nManages authentication details for Kibana.\nNote that this will always report changes since there is\nno way to read the current configuration.\nDepends on `elastic.kibana.package`_.\n\n\n``elastic.kibana.certs``\n^^^^^^^^^^^^^^^^^^^^^^^^\nGenerates client certificates and ensures\nthe CA is trusted by Kibana.\nDepends on `elastic.kibana.package`_.\n\n\n``elastic.kibana.config``\n^^^^^^^^^^^^^^^^^^^^^^^^^\nManages Kibana configuration, other than authentication.\nDepends on `elastic.kibana.package`_.\n\n\n``elastic.kibana.package``\n^^^^^^^^^^^^^^^^^^^^^^^^^^\nInstalls the Kibana package only.\nDepends on `elastic.repo`_.\n\n\n``elastic.kibana.service``\n^^^^^^^^^^^^^^^^^^^^^^^^^^\nEnables and (re-)starts Kibana.\nDepends on `elastic.kibana.config`_, `elastic.kibana.certs`_\nand `elastic.kibana.auth`_.\n\n\n``elastic.logstash``\n^^^^^^^^^^^^^^^^^^^^\nInstalls, configures and starts Filebeat.\n\n\n``elastic.logstash.config``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.logstash.package``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.logstash.service``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.metricbeat``\n^^^^^^^^^^^^^^^^^^^^^^\nInstalls, configures and starts Metricbeat.\n\n\n``elastic.metricbeat.config``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.metricbeat.package``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.metricbeat.service``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.packetbeat``\n^^^^^^^^^^^^^^^^^^^^^^\nInstalls, configures and starts Packetbeat.\n\n\n``elastic.packetbeat.config``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.packetbeat.package``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.packetbeat.service``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.clean``\n^^^^^^^^^^^^^^^^^\n*Meta-state*.\n\nRemoves everything Elastic-related:\nincludes all clean states.\n\n\n``elastic.repo.clean``\n^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.auditbeat.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^\nStops, unconfigures and removes Auditbeat.\n\n\n``elastic.auditbeat.config.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.auditbeat.package.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.auditbeat.service.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.elasticsearch.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nUndoes everything in the `elastic.elasticsearch`_ state in reverse.\n\n\n``elastic.elasticsearch.auth.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nRemoves the Vault database connection, only if\n``remove_all_data_for_sure`` is true.\nDepends on `elastic.elasticsearch.service.clean`_.\n\n\n``elastic.elasticsearch.bootstrap_pass.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nEnsures no bootstrap password is set.\nDepends on `elastic.elasticsearch.service.clean`_.\n\n\n``elastic.elasticsearch.certs.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nEnsures certificates and keys are removed from ES configuration\nand the local filesystem.\nDepends on `elastic.elasticsearch.service.clean`_.\n\n\n``elastic.elasticsearch.config.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nRemoves Elasticsearch and JVM configuration files.\nDepends on `elastic.elasticsearch.service.clean`_.\n\n\n``elastic.elasticsearch.package.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nRemoves Elasticsearch.\nDepends on `elastic.elasticsearch.config.clean`_.\n\n\n``elastic.elasticsearch.service.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nStops and disables Elasticsearch at boot time.\n\n\n``elastic.elasticsearch.vault_roles.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nRemoves managed Vault roles.\n\n\n``elastic.elasticsearch.vault_setup.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nRemoves generated certificate and key from the Vault server's filesystem.\n\n\n``elastic.filebeat.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^\nStops, unconfigures and removes Filebeat.\n\n\n``elastic.filebeat.config.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.filebeat.package.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.filebeat.service.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.functionbeat.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nStops, unconfigures and removes Functionbeat.\n\n\n``elastic.functionbeat.config.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.functionbeat.package.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.functionbeat.service.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.heartbeat.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^\nStops, unconfigures and removes Heartbeat.\n\n\n``elastic.heartbeat.config.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.heartbeat.package.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.heartbeat.service.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.kibana.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^\nUndoes everything in the `elastic.kibana`_ state in reverse.\n\n\n``elastic.kibana.auth.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nRemoves authentication credentials from the Kibana keystore.\nDepends on `elastic.kibana.service.clean`_.\n\n\n``elastic.kibana.certs.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nRemoves generated Kibana certificates and keys.\nDepends on `elastic.kibana.service.clean`_.\n\n\n``elastic.kibana.config.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nRemoves Kibana the configuration file.\nDepends on `elastic.kibana.service.clean`_.\n\n\n``elastic.kibana.package.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nRemoves Kibana from the system.\nDepends on `elastic.kibana.config.clean`_.\n\n\n``elastic.kibana.service.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nStops and disables Kibana at boot time.\n\n\n``elastic.logstash.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^\nStops, unconfigures and removes Logstash.\n\n\n``elastic.logstash.config.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.logstash.package.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.logstash.service.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.metricbeat.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nStops, unconfigures and removes Metricbeat.\n\n\n``elastic.metricbeat.config.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.metricbeat.package.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.metricbeat.service.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.packetbeat.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nStops, unconfigures and removes Packetbeat.\n\n\n``elastic.packetbeat.config.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.packetbeat.package.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n``elastic.packetbeat.service.clean``\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n\n\n\nContributing to this repo\n-------------------------\n\nCommit messages\n^^^^^^^^^^^^^^^\n\n**Commit message formatting is significant!**\n\nPlease see `How to contribute \u003chttps://github.com/saltstack-formulas/.github/blob/master/CONTRIBUTING.rst\u003e`_ for more details.\n\npre-commit\n^^^^^^^^^^\n\n`pre-commit \u003chttps://pre-commit.com/\u003e`_ is configured for this formula, which you may optionally use to ease the steps involved in submitting your changes.\nFirst install  the ``pre-commit`` package manager using the appropriate `method \u003chttps://pre-commit.com/#installation\u003e`_, then run ``bin/install-hooks`` and\nnow ``pre-commit`` will run automatically on each ``git commit``. ::\n\n  $ bin/install-hooks\n  pre-commit installed at .git/hooks/pre-commit\n  pre-commit installed at .git/hooks/commit-msg\n\nState documentation\n~~~~~~~~~~~~~~~~~~~\nThere is a script that semi-autodocuments available states: ``bin/slsdoc``.\n\nIf a ``.sls`` file begins with a Jinja comment, it will dump that into the docs. It can be configured differently depending on the formula. See the script source code for details currently.\n\nThis means if you feel a state should be documented, make sure to write a comment explaining it.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flkubb%2Fsalt-elastic-formula","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flkubb%2Fsalt-elastic-formula","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flkubb%2Fsalt-elastic-formula/lists"}