Skip to content

Commit

Permalink
fix: private key path
Browse files Browse the repository at this point in the history
  • Loading branch information
storytellerF committed Dec 8, 2024
1 parent cbe6d72 commit a285a32
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions scripts/build_scripts/build-service-on-ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,14 @@ fi

chmod 600 ./remote.pem

## 检查 known_hosts 文件是否存在
#if [ ! -f ~/.ssh/known_hosts ]; then
# # 如果文件不存在,创建空的 known_hosts 文件
# mkdir -p ~/.ssh
# touch ~/.ssh/known_hosts
#fi
#
#ssh-keyscan -H acommunity.link >> ~/.ssh/known_hosts
# 检查 known_hosts 文件是否存在
if [ ! -f ~/.ssh/known_hosts ]; then
# 如果文件不存在,创建空的 known_hosts 文件
mkdir -p ~/.ssh
touch ~/.ssh/known_hosts
fi

ssh-keyscan -p 422 -H acommunity.link >> ~/.ssh/known_hosts

HOST_TYPE=local \
./scripts/service_scripts/build-service.sh "s-$FLAVOR" ubuntu@acommunity.link ./remote.pem "sudo bash ./start.sh"
2 changes: 1 addition & 1 deletion scripts/service_scripts/push-image-to-remote.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ else
echo "$FILE already exists. Skipping docker save."
fi

./scripts/tool_scripts/exec-until-success.sh ssh -o StrictHostKeyChecking=accept-new -i "$REMOTE_CERT_FILE" -p 422 "$REMOTE_URI" "mkdir -p a-server && mkdir -p /tmp/A"
./scripts/tool_scripts/exec-until-success.sh ssh -i "$REMOTE_CERT_FILE" -p 422 "$REMOTE_URI" "mkdir -p a-server && mkdir -p /tmp/A"
sleep 2

md=$(md5sum "$FILE" | awk '{print $1}')
Expand Down

0 comments on commit a285a32

Please sign in to comment.