Skip to content

Commit

Permalink
Merge pull request #2229 from wenchajun/autoesupdate
Browse files Browse the repository at this point in the history
Support automatic update of external elasticsearch or opensearch username and password
  • Loading branch information
ks-ci-bot authored Aug 25, 2023
2 parents 0b2a497 + fd8283c commit 6bc800c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion roles/common/tasks/escurator-install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
# Creating elasticsearch-credentials secret used to connect external es with basic auth enabled.
- name: KubeSphere | Creating elasticsearch credentials secret
shell: >
{{ bin_dir }}/kubectl create secret generic elasticsearch-credentials --from-literal="username={{ common.es.basicAuth.username }}" --from-literal="password={{ common.es.basicAuth.password }}" --type=kubernetes.io/basic-auth -n kubesphere-logging-system
{{ bin_dir }}/kubectl create secret generic elasticsearch-credentials --save-config --dry-run=client --from-literal="username={{ common.es.basicAuth.username }}" --from-literal="password={{ common.es.basicAuth.password }}" --type=kubernetes.io/basic-auth -n kubesphere-logging-system -o yaml | kubectl apply -f -
register: secret
failed_when: "secret.stderr and 'already exists' not in secret.stderr"
until: secret is succeeded
Expand Down
2 changes: 1 addition & 1 deletion roles/common/tasks/opensearch-install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
# Creating opensearch-credentials secret used to connect external es with basic auth enabled.
- name: KubeSphere | Creating opensearch credentials secret
shell: >
{{ bin_dir }}/kubectl create secret generic opensearch-credentials --from-literal="username={{ common.opensearch.basicAuth.username }}" --from-literal="password={{ common.opensearch.basicAuth.password }}" --type=kubernetes.io/basic-auth -n kubesphere-logging-system
{{ bin_dir }}/kubectl create secret generic opensearch-credentials --save-config --dry-run=client --from-literal="username={{ common.opensearch.basicAuth.username }}" --from-literal="password={{ common.opensearch.basicAuth.password }}" --type=kubernetes.io/basic-auth -n kubesphere-logging-system -o yaml | kubectl apply -f -
register: secret
failed_when: "secret.stderr and 'already exists' not in secret.stderr"
until: secret is succeeded
Expand Down

0 comments on commit 6bc800c

Please sign in to comment.