Skip to content

Commit

Permalink
try env var
Browse files Browse the repository at this point in the history
Signed-off-by: Stephen Crawford <[email protected]>
  • Loading branch information
stephen-crawford committed Sep 20, 2023
1 parent 6de3f67 commit 542a66f
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions .github/workflows/plugin_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,17 +36,10 @@ jobs:
run: mv ./build/distributions/${{ env.PLUGIN_NAME }}-*.zip ${{ env.PLUGIN_NAME }}.zip
shell: bash

- name: Populate password file
run: |
echo installPassword > ./config/initialAdminPassword.txt
cd config
cat initialAdminPassword.txt
- name: Create Setup Script
if: ${{ runner.os == 'Linux' }}
run: |
export initialAdminPassword=installPassword
cat > setup.sh <<'EOF'
chmod +x ./opensearch-${{ env.OPENSEARCH_VERSION }}-SNAPSHOT/plugins/${{ env.PLUGIN_NAME }}/tools/install_demo_configuration.sh
/bin/bash -c "yes | ./opensearch-${{ env.OPENSEARCH_VERSION }}-SNAPSHOT/plugins/${{ env.PLUGIN_NAME }}/tools/install_demo_configuration.sh"
Expand All @@ -55,6 +48,7 @@ jobs:
- name: Create Setup Script
if: ${{ runner.os == 'Windows' }}
run: |
set initialAdminPassword=installPassword
New-Item .\setup.bat -type file
Set-Content .\setup.bat -Value "powershell.exe .\opensearch-${{ env.OPENSEARCH_VERSION }}-SNAPSHOT\plugins\${{ env.PLUGIN_NAME }}\tools\install_demo_configuration.bat -i -c -y"
Get-Content .\setup.bat
Expand Down

0 comments on commit 542a66f

Please sign in to comment.