Skip to content

Commit b69dc77

Browse files
authored
Merge pull request XCSoar#253 from kerel-fs/pr/fix_gitlab_ci
WIP: Fix upload of nightlies to download.xcsoar.org
2 parents 6982ca5 + c89c7ba commit b69dc77

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

.gitlab-ci.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,12 +130,16 @@ nightly-docs:
130130

131131
deploy_nightlies:
132132
stage: deploy
133+
before_script:
134+
- apk update && apk add openssh-client rsync
133135
script:
134-
- 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )'
135136
- eval $(ssh-agent -s)
136137
- echo "$SSH_PRIVATE_KEY" | tr -d '\r' | ssh-add - > /dev/null
137138
- mkdir -p ~/.ssh
138139
- chmod 700 ~/.ssh
139-
- scp -P ${DEPLOY_PORT} ./output ${DEPLOY_USER}@${DEPLOY_HOST}:${DEPLOY_PATH}
140+
- export DIRECTORY="$(cat VERSION.txt)~git#$CI_COMMIT_SHORT_SHA"
141+
- rsync -e "ssh -o StrictHostKeyChecking=no -p ${DEPLOY_PORT}" -r ./output/* ${DEPLOY_USER}@${DEPLOY_HOST}:${DEPLOY_PATH}/${DIRECTORY}/
140142
only:
141143
- master
144+
except:
145+
- tags

0 commit comments

Comments
 (0)