Skip to content

Commit acc3aa8

Browse files
author
Othman El Hammouchi
committed
Change env var disabling security plugin
1 parent b1642e9 commit acc3aa8

File tree

1 file changed

+2
-3
lines changed
  • modules/opensearch/testcontainers/opensearch

1 file changed

+2
-3
lines changed

modules/opensearch/testcontainers/opensearch/__init__.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,10 @@
22

33
from opensearchpy import OpenSearch
44
from opensearchpy.exceptions import ConnectionError, TransportError
5-
from urllib3.exceptions import ProtocolError
6-
75
from testcontainers.core.container import DockerContainer
86
from testcontainers.core.utils import raise_for_deprecated_parameter
97
from testcontainers.core.waiting_utils import wait_container_is_ready
8+
from urllib3.exceptions import ProtocolError
109

1110

1211
class OpenSearchContainer(DockerContainer):
@@ -57,7 +56,7 @@ def __init__(
5756

5857
self.with_exposed_ports(self.port)
5958
self.with_env("discovery.type", "single-node")
60-
self.with_env("plugins.security.disabled", "false" if security_enabled else "true")
59+
self.with_env("DISABLE_SECURITY_PLUGIN", "false" if security_enabled else "true")
6160
if self._supports_initial_admin_password(str(image)):
6261
self.with_env("OPENSEARCH_INITIAL_ADMIN_PASSWORD", self.initial_admin_password)
6362
if security_enabled:

0 commit comments

Comments
 (0)