first version of the deploy to fdroid-repo job

This commit is contained in:
Micha Gläß-Stöcker 2021-07-11 19:40:34 +00:00 committed by Georg Krause
parent 476c987db1
commit 488398bc8a
1 changed files with 13 additions and 0 deletions

View File

@ -2,6 +2,7 @@ image: jangrewe/gitlab-ci-android
stages:
- build
- deploy
before_script:
- export GRADLE_USER_HOME=$(pwd)/.gradle
@ -20,3 +21,15 @@ build:
artifacts:
paths:
- app/build/outputs/apk/debug/app-debug.apk
deploy-develop:
stage: deploy
only:
- develop
script:
- eval `ssh-agent -s`
- ssh-add <(echo "$SSH_PRIVATE_KEY")
- scp -o StrictHostKeyChecking=no app/build/outputs/apk/debug/app-debug.apk fdroid@apps.funkwhale.audio:/srv/fdroid/fdroid/develop/repo/org.funkwhale.ffa.dev-$CI_COMMIT_SHORT_SHA.apk
- ssh -o StrictHostKeyChecking=no fdroid@apps.funkwhale.audio 'docker run --rm -u $(id -u):$(id -g) -v /srv/fdroid/fdroid/develop:/repo registry.gitlab.com/fdroid/docker-executable-fdroidserver:master update'
tags:
- shell