Skip to content

Commit

Permalink
Add ssl path option when building the librdkafka dependency (DataDog#…
Browse files Browse the repository at this point in the history
…17957)

* add the prefix path

* commit

* commit

* commit

* add debug

* enable ssl

* enable ssl in prefix folder

* enable ssl in prefix folder

* set default ssl path

* set default ssl path

* set default ssl path

* set default ssl path

* set default ssl path

* linter

* linter
  • Loading branch information
HadhemiDD authored and ravindrasojitra-crest committed Aug 5, 2024
1 parent 1e8e209 commit 96e6625
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions kafka_consumer/datadog_checks/kafka_consumer/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,13 @@ def __init__(self, init_config, instance, log) -> None:
else:
self._tls_verify = "true" if is_affirmative(instance.get("tls_verify", True)) else "false"

if (
not self._tls_ca_cert
and os.name != 'nt'
and os.path.exists('/opt/datadog-agent/embedded/ssl/certs/cacert.pem')
):
self._tls_ca_cert = '/opt/datadog-agent/embedded/ssl/certs/cacert.pem'

def validate_config(self):
if not self._kafka_connect_str:
raise ConfigurationError('`kafka_connect_str` is required')
Expand Down

0 comments on commit 96e6625

Please sign in to comment.