2019-12-15 21:49:18 +00:00
|
|
|
#!/usr/bin/env sh
|
|
|
|
|
|
|
|
export SSHDIR="$HOME/.ssh"
|
|
|
|
mkdir -p "$SSHDIR"
|
|
|
|
echo "$ACTIONS_DEPLOY_KEY" > "$SSHDIR/key"
|
|
|
|
chmod 600 "$SSHDIR/key"
|
|
|
|
export SERVER_DEPLOY_STRING="$SSH_USERNAME@$SERVER_ADDRESS:$SERVER_DESTINATION"
|
2020-07-02 18:23:31 +00:00
|
|
|
mkdir -p "$GITHUB_WORKSPACE/APS"
|
|
|
|
cp -v "$GITHUB_WORKSPACE/app/build/outputs/apk/free/release/*.apk" "$GITHUB_WORKSPACE/APS"
|
|
|
|
cp -v "$GITHUB_WORKSPACE/app/build/outputs/apk/nonFree/release/*.apk" "$GITHUB_WORKSPACE/APS"
|
|
|
|
cd "$GITHUB_WORKSPACE/APS"
|
2020-04-19 11:22:14 +00:00
|
|
|
rsync -ahvcr --omit-dir-times --progress --delete --no-o --no-g -e "ssh -i $SSHDIR/key -o StrictHostKeyChecking=no -p $SSH_PORT" . "$SERVER_DEPLOY_STRING" || exit 1
|
2019-12-15 21:49:18 +00:00
|
|
|
exit 0
|