Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix conditional installs #186

Merged
merged 1 commit into from
Jun 28, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions jobs/ci-run/integration/common/test-runner.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,24 +37,24 @@ sudo apt-get -y update
# set, so retries succeed.
attempts=0
while [ $attempts -lt 3 ]; do
if [ ! "$(which jq >/dev/null 2>&1)" ]; then
if ! which jq >/dev/null 2>&1; then
sudo snap install jq || true
fi
if [ ! "$(which yq >/dev/null 2>&1)" ]; then
if ! which yq >/dev/null 2>&1; then
sudo snap install yq || true
fi
if [ ! "$(which shellcheck >/dev/null 2>&1)" ]; then
if ! which shellcheck >/dev/null 2>&1; then
sudo snap install shellcheck || true
fi
if [ ! "$(which expect >/dev/null 2>&1)" ]; then
if ! which expect >/dev/null 2>&1; then
sudo apt-get -y install expect || true
fi
if [ ! "$(which petname >/dev/null 2>&1)" ]; then
if ! which petname >/dev/null 2>&1; then
sudo snap install petname || true
fi
# shellcheck disable=SC2193
if [ "${{BOOTSTRAP_PROVIDER:-}}" = "ec2" ]; then
if [ ! "$(which aws >/dev/null 2>&1)" ]; then
if ! which aws >/dev/null 2>&1; then
sudo snap install aws-cli --classic || true
fi

Expand All @@ -71,7 +71,7 @@ while [ $attempts -lt 3 ]; do
fi
# shellcheck disable=SC2193
if [ "${{BOOTSTRAP_PROVIDER:-}}" = "azure" ]; then
if [ ! "$(which az >/dev/null 2>&1)" ]; then
if ! which az >/dev/null 2>&1; then
curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash
fi

Expand Down
Loading