fix(ci): prioritize /root/.ssh/gitea_ci_key mount
This commit is contained in:
@@ -128,8 +128,8 @@ jobs:
|
||||
|
||||
docker run --rm --net=host \
|
||||
-v "$(pwd):/workspace" -w /workspace \
|
||||
-v "/root/.ssh:/root/.ssh:ro" \
|
||||
-v "/home/ubuntu/.ssh:/home/ubuntu/.ssh:ro" \
|
||||
-v "${HOME}/.ssh:/root/.ssh:ro" \
|
||||
-e TARGET_HOST="${TARGET_HOST}" \
|
||||
-e TARGET_USER="${TARGET_USER}" \
|
||||
-e PORT="${PORT}" \
|
||||
@@ -137,7 +137,7 @@ jobs:
|
||||
alpine:latest sh -c '
|
||||
apk add --no-cache openssh-client rsync && \
|
||||
KEY_ARG="" && \
|
||||
for k in /home/ubuntu/.ssh/gitea_ci_key /root/.ssh/gitea_ci_key /home/ubuntu/.ssh/id_ed25519 /root/.ssh/id_ed25519 /home/ubuntu/.ssh/id_rsa /root/.ssh/id_rsa; do \
|
||||
for k in /root/.ssh/gitea_ci_key /home/ubuntu/.ssh/gitea_ci_key /root/.ssh/id_ed25519 /root/.ssh/id_rsa; do \
|
||||
if [ -f "$k" ]; then \
|
||||
KEY_ARG="-i $k -o IdentitiesOnly=yes" && break ; \
|
||||
fi ; \
|
||||
|
||||
Reference in New Issue
Block a user