Skip to content

Commit

Permalink
Run commands as sudo when needed
Browse files Browse the repository at this point in the history
Signed-off-by: Shubhendu Ram Tripathi <shubhendu@minio.io>
  • Loading branch information
shtripat committed Jan 10, 2024
1 parent e0f3081 commit 4860420
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions kesconf/testdata/vault/deploy_vault.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,14 @@ function init_setup() {
echo ""
echo "Initialize setup....."
echo ""
apt update -y && apt upgrade -y && apt install wget unzip
apt update -y || sudo apt update -y
apt upgrade -y || sudo apt upgrade -y
apt install wget unzip || sudo apt install wget unzip
sudo chmod a+x /usr/local/bin/yq
wget https://releases.hashicorp.com/vault/1.15.2/vault_1.15.2_linux_amd64.zip

rm -rf /vault/file
pkill -9 vault
rm -rf /vault/file || sudo rm -rf /vault/file
pkill -9 vault || sudo pkill -9 vault
rm -f client.crt client.key private.key public.crt vault.crt vault.key
}

Expand Down

0 comments on commit 4860420

Please sign in to comment.