Skip to content

Commit 2f57dec

Browse files
test(smoke): Apply secrets before the OpenSearch cluster to avoid restarts (#98)
* test(smoke): Apply secrets before the OpenSearch cluster to avoid restarts * test(smoke): Do not apply the opensearch-security-config Secret twice
1 parent e69611e commit 2f57dec

File tree

3 files changed

+96
-96
lines changed

3 files changed

+96
-96
lines changed
Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
---
2+
apiVersion: v1
3+
kind: Secret
4+
metadata:
5+
name: opensearch-security-config
6+
stringData:
7+
action_groups.yml: |
8+
---
9+
_meta:
10+
type: actiongroups
11+
config_version: 2
12+
allowlist.yml: |
13+
---
14+
_meta:
15+
type: allowlist
16+
config_version: 2
17+
18+
config:
19+
enabled: false
20+
audit.yml: |
21+
---
22+
_meta:
23+
type: audit
24+
config_version: 2
25+
26+
config:
27+
enabled: false
28+
config.yml: |
29+
---
30+
_meta:
31+
type: config
32+
config_version: 2
33+
34+
config:
35+
dynamic:
36+
authc:
37+
basic_internal_auth_domain:
38+
description: Authenticate via HTTP Basic against internal users database
39+
http_enabled: true
40+
transport_enabled: true
41+
order: 1
42+
http_authenticator:
43+
type: basic
44+
challenge: true
45+
authentication_backend:
46+
type: intern
47+
authz: {}
48+
internal_users.yml: |
49+
---
50+
# The hash value is a bcrypt hash and can be generated with plugin/tools/hash.sh
51+
52+
_meta:
53+
type: internalusers
54+
config_version: 2
55+
56+
admin:
57+
hash: $2y$10$xRtHZFJ9QhG9GcYhRpAGpufCZYsk//nxsuel5URh0GWEBgmiI4Q/e
58+
reserved: true
59+
backend_roles:
60+
- admin
61+
description: OpenSearch admin user
62+
63+
kibanaserver:
64+
hash: $2y$10$vPgQ/6ilKDM5utawBqxoR.7euhVQ0qeGl8mPTeKhmFT475WUDrfQS
65+
reserved: true
66+
description: OpenSearch Dashboards user
67+
nodes_dn.yml: |
68+
---
69+
_meta:
70+
type: nodesdn
71+
config_version: 2
72+
roles.yml: |
73+
---
74+
_meta:
75+
type: roles
76+
config_version: 2
77+
roles_mapping.yml: |
78+
---
79+
_meta:
80+
type: rolesmapping
81+
config_version: 2
82+
83+
all_access:
84+
reserved: false
85+
backend_roles:
86+
- admin
87+
88+
kibana_server:
89+
reserved: true
90+
users:
91+
- kibanaserver
92+
tenants.yml: |
93+
---
94+
_meta:
95+
type: tenants
96+
config_version: 2
File renamed without changes.

tests/templates/kuttl/smoke/10-install-opensearch.yaml.j2 renamed to tests/templates/kuttl/smoke/11-install-opensearch.yaml.j2

Lines changed: 0 additions & 96 deletions
Original file line numberDiff line numberDiff line change
@@ -75,99 +75,3 @@ spec:
7575
secret:
7676
secretName: opensearch-security-config
7777
defaultMode: 0o660
78-
---
79-
apiVersion: v1
80-
kind: Secret
81-
metadata:
82-
name: opensearch-security-config
83-
stringData:
84-
action_groups.yml: |
85-
---
86-
_meta:
87-
type: actiongroups
88-
config_version: 2
89-
allowlist.yml: |
90-
---
91-
_meta:
92-
type: allowlist
93-
config_version: 2
94-
95-
config:
96-
enabled: false
97-
audit.yml: |
98-
---
99-
_meta:
100-
type: audit
101-
config_version: 2
102-
103-
config:
104-
enabled: false
105-
config.yml: |
106-
---
107-
_meta:
108-
type: config
109-
config_version: 2
110-
111-
config:
112-
dynamic:
113-
authc:
114-
basic_internal_auth_domain:
115-
description: Authenticate via HTTP Basic against internal users database
116-
http_enabled: true
117-
transport_enabled: true
118-
order: 1
119-
http_authenticator:
120-
type: basic
121-
challenge: true
122-
authentication_backend:
123-
type: intern
124-
authz: {}
125-
internal_users.yml: |
126-
---
127-
# The hash value is a bcrypt hash and can be generated with plugin/tools/hash.sh
128-
129-
_meta:
130-
type: internalusers
131-
config_version: 2
132-
133-
admin:
134-
hash: $2y$10$xRtHZFJ9QhG9GcYhRpAGpufCZYsk//nxsuel5URh0GWEBgmiI4Q/e
135-
reserved: true
136-
backend_roles:
137-
- admin
138-
description: OpenSearch admin user
139-
140-
kibanaserver:
141-
hash: $2y$10$vPgQ/6ilKDM5utawBqxoR.7euhVQ0qeGl8mPTeKhmFT475WUDrfQS
142-
reserved: true
143-
description: OpenSearch Dashboards user
144-
nodes_dn.yml: |
145-
---
146-
_meta:
147-
type: nodesdn
148-
config_version: 2
149-
roles.yml: |
150-
---
151-
_meta:
152-
type: roles
153-
config_version: 2
154-
roles_mapping.yml: |
155-
---
156-
_meta:
157-
type: rolesmapping
158-
config_version: 2
159-
160-
all_access:
161-
reserved: false
162-
backend_roles:
163-
- admin
164-
165-
kibana_server:
166-
reserved: true
167-
users:
168-
- kibanaserver
169-
tenants.yml: |
170-
---
171-
_meta:
172-
type: tenants
173-
config_version: 2

0 commit comments

Comments
 (0)