Skip to content

Commit

Permalink
Update admin default password in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
ElliottKasoar committed Mar 11, 2024
1 parent 1c4014b commit 73b0673
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions .ci/opensearch/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ inputs:
description: 'Port where you want to run OpenSearch'
required: false
default: 9200
opensearch_password:
opensearch-initial-admin-password:
description: 'The password for the user admin in your cluster'
required: false
default: 'admin'
default: 'myStrongPassword123!'

runs:
using: 'docker'
Expand All @@ -30,3 +30,4 @@ runs:
NODES: ${{ inputs.nodes }}
PORT: ${{ inputs.port }}
SECURITY_ENABLED: ${{ inputs.security-enabled }}
OPENSEARCH_INITIAL_ADMIN_PASSWORD: ${{ inputs.opensearch-initial-admin-password }}
3 changes: 2 additions & 1 deletion .ci/opensearch/run-opensearch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ do
port=$((PORT + $node - 1))

if [[ "$SECURITY_ENABLED" == "true" ]]; then
healthcmd="curl -vvv -s --insecure -u admin:admin --fail https://localhost:$port/_cluster/health || exit 1"
healthcmd="curl -vvv -s --insecure -u admin:$OPENSEARCH_INITIAL_ADMIN_PASSWORD --fail https://localhost:$port/_cluster/health || exit 1"
security=($(cat <<-END
END
Expand All @@ -34,6 +34,7 @@ END
--env discovery.type=single-node \
--env bootstrap.memory_lock=true \
--env "OPENSEARCH_JAVA_OPTS=-Xms4g -Xmx4g" \
--env OPENSEARCH_INITIAL_ADMIN_PASSWORD=$OPENSEARCH_INITIAL_ADMIN_PASSWORD \
"${security[@]}" \
--publish "${port}:${port}" \
--ulimit nofile=65536:65536 \
Expand Down

0 comments on commit 73b0673

Please sign in to comment.