Skip to content

Commit

Permalink
Fixed syntax
Browse files Browse the repository at this point in the history
Signed-off-by: Owais Kazi <[email protected]>
  • Loading branch information
owaiskazi19 committed Sep 7, 2022
1 parent 454a381 commit fe99af8
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/code-hygiene.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ jobs:

- name: Linelint
uses: fernandrone/[email protected]
shellcheck:
name: Shellcheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Run ShellCheck
uses: ludeeus/action-shellcheck@master
with:
ignore_paths: "*/gradlew"
shellcheck:
name: Shellcheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Run ShellCheck
uses: ludeeus/action-shellcheck@master
with:
ignore_paths: "*/gradlew"
5 changes: 3 additions & 2 deletions client/sniffer/src/test/resources/create_test_nodes_info.bash
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,18 @@ function do_version() {

tar xf ../opensearch-min-${version}-linux-x64.tar.gz
local http_port=9200
local cluster_manager initial_cluster_manager_nodes data
for node in ${nodes}; do
mkdir ${node}
cp -r opensearch-${version}/* ${node}
local cluster_manager=$([[ "$node" =~ ^m.* ]] && echo 'cluster_manager,' || echo '')
cluster_manager=$([[ "$node" =~ ^m.* ]] && echo 'cluster_manager,' || echo '')
# 'cluster_manager' role is add in version 2.x and above, use 'master' role in 1.x
cluster_manager=$([[ ! "$cluster_manager" == '' && ${version} =~ ^1\. ]] && echo 'master,' || echo ${cluster_manager})
local data=$([[ "$node" =~ ^d.* ]] && echo 'data,' || echo '')
# m2 is always cluster_manager and data for these test just so we have a node like that
data=$([[ "$node" == 'm2' ]] && echo 'data,' || echo ${data})
# setting name 'cluster.initial_cluster_manager_nodes' is add in version 2.x and above
local initial_cluster_manager_nodes=$([[ ${version} =~ ^1\. ]] && echo 'initial_master_nodes' || echo 'initial_cluster_manager_nodes')
initial_cluster_manager_nodes=$([[ ${version} =~ ^1\. ]] && echo 'initial_master_nodes' || echo 'initial_cluster_manager_nodes')
local transport_port=$((http_port+100))

cat >> ${node}/config/opensearch.yml << __OPENSEARCH_YML
Expand Down

0 comments on commit fe99af8

Please sign in to comment.