Skip to content

Commit

Permalink
Fixed SSH setup in scripts.
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexSkrypnyk committed Apr 25, 2024
1 parent cc0e066 commit 5e4bf06
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion scripts/drevops/deploy-artifact.sh
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ info "Started ARTIFACT deployment."
[ "$(git config --global user.name)" = "" ] && note "Configuring global git user name." && git config --global user.name "${DREVOPS_DEPLOY_ARTIFACT_GIT_USER_NAME}"
[ "$(git config --global user.email)" = "" ] && note "Configuring global git user email." && git config --global user.email "${DREVOPS_DEPLOY_ARTIFACT_GIT_USER_EMAIL}"

DREVOPS_SSH_PREFIX="DEPLOY" ./scripts/drevops/setup-ssh.sh
export DREVOPS_SSH_PREFIX="DEPLOY" && . ./scripts/drevops/setup-ssh.sh

note "Installing artifact builder."
composer global require --dev -n --ansi --prefer-source --ignore-platform-reqs drevops/git-artifact:^0.7
Expand Down
2 changes: 1 addition & 1 deletion scripts/drevops/deploy-lagoon.sh
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ info "Started LAGOON deployment."
[ -z "${LAGOON_PROJECT}" ] && fail "Missing required value for LAGOON_PROJECT." && exit 1
{ [ -z "${DREVOPS_DEPLOY_BRANCH}" ] && [ -z "${DREVOPS_DEPLOY_PR}" ]; } && fail "Missing required value for DREVOPS_DEPLOY_BRANCH or DREVOPS_DEPLOY_PR." && exit 1

DREVOPS_SSH_PREFIX="DEPLOY" ./scripts/drevops/setup-ssh.sh
export DREVOPS_SSH_PREFIX="DEPLOY" && . ./scripts/drevops/setup-ssh.sh

if ! command -v lagoon >/dev/null || [ -n "${DREVOPS_LAGOONCLI_FORCE_INSTALL}" ]; then
note "Installing Lagoon CLI."
Expand Down
2 changes: 1 addition & 1 deletion scripts/drevops/download-db-lagoon.sh
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ if [ -f ".env.local" ]; then
t=$(mktemp) && export -p >"${t}" && set -a && . ".env.local" && set +a && . "${t}" && rm "${t}" && unset t
fi

DREVOPS_SSH_PREFIX="DB_DOWNLOAD" ./scripts/drevops/setup-ssh.sh
export DREVOPS_SSH_PREFIX="DB_DOWNLOAD" && . ./scripts/drevops/setup-ssh.sh

ssh_opts=(-o "UserKnownHostsFile=/dev/null")
ssh_opts+=(-o "StrictHostKeyChecking=no")
Expand Down
2 changes: 1 addition & 1 deletion scripts/drevops/mirror-code.sh
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ info "Started code mirroring."
[ "$(git config --global user.name)" == "" ] && note "Configuring global git user name." && git config --global user.name "${DREVOPS_MIRROR_CODE_GIT_USER_NAME}"
[ "$(git config --global user.email)" == "" ] && note "Configuring global git user email." && git config --global user.email "${DREVOPS_MIRROR_CODE_GIT_USER_EMAIL}"

DREVOPS_SSH_PREFIX="MIRROR_CODE" ./scripts/drevops/setup-ssh.sh
export DREVOPS_SSH_PREFIX="MIRROR_CODE" && . ./scripts/drevops/setup-ssh.sh

# Create a temp directory to copy source repository into to prevent changes to source.
SRC_TMPDIR=$(mktemp -d)
Expand Down
2 changes: 1 addition & 1 deletion scripts/drevops/task-custom-lagoon.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ info "Started Lagoon task ${DREVOPS_TASK_LAGOON_NAME}."
[ -z "${DREVOPS_TASK_LAGOON_COMMAND}" ] && echo "Missing required value for DREVOPS_TASK_LAGOON_COMMAND." && exit 1
[ -z "${DREVOPS_TASK_LAGOON_PROJECT}" ] && echo "Missing required value for DREVOPS_TASK_LAGOON_PROJECT." && exit 1

DREVOPS_SSH_PREFIX="TASK" ./scripts/drevops/setup-ssh.sh
export DREVOPS_SSH_PREFIX="TASK" && . ./scripts/drevops/setup-ssh.sh

if ! command -v lagoon >/dev/null || [ -n "${DREVOPS_LAGOONCLI_FORCE_INSTALL}" ]; then
note "Installing Lagoon CLI."
Expand Down

1 comment on commit 5e4bf06

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.