diff options
| author | Menny Even Danan <menny@evendanan.net> | 2020-03-02 15:03:03 +0000 |
|---|---|---|
| committer | Menny Even Danan <menny@evendanan.net> | 2020-03-10 15:12:01 +0000 |
| commit | 75a0d3e3a6ba8bb187e2957c4f9e34c5b4f6ed5b (patch) | |
| tree | 4157a08b179fb4c1febc6d3d4c8b6cada633d3ea /.github/workflows | |
| parent | 2e9762f38bb0f779d75990b0e18687d64b5137a1 (diff) | |
| download | AnySoftKeyboard-75a0d3e3a6ba8bb187e2957c4f9e34c5b4f6ed5b.tar.gz AnySoftKeyboard-75a0d3e3a6ba8bb187e2957c4f9e34c5b4f6ed5b.tar.bz2 | |
Deploy-Request Gradle task and definition of promoting steps
Diffstat (limited to '.github/workflows')
| -rw-r--r-- | .github/workflows/checks.yml | 26 | ||||
| -rw-r--r-- | .github/workflows/deploy.yml | 33 | ||||
| -rw-r--r-- | .github/workflows/deployment_promote.yml | 21 |
3 files changed, 45 insertions, 35 deletions
diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index f50c93807..f23635919 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -165,7 +165,6 @@ jobs: path: build-logging deploy-dry-run: - if: github.event_name == 'pull_request' runs-on: ubuntu-18.04 container: menny/ndk_ask:1.13.6 steps: @@ -178,9 +177,12 @@ jobs: dry-run-deploy-gradle- - name: setup run: ./scripts/ci/ci_setup.sh - - uses: ./.github/actions/deploy - with: - deploy_target: dry-run + - name: dry-run-release-build + run: | + mkdir -p /root/.android/ || true + cp ./.github/actions/deploy/debug.keystore /root/.android/ || exit 1 + ./gradlew -PwithAutoVersioning :generateFdroidYamls -DdeployChannel=alpha assembleRelease assembleCanary verifyReleaseResources generateReleasePlayResources generateCanaryPlayResources + chmod -R a+rwx . - uses: actions/upload-artifact@v1.0.0 with: name: fdroid-metadata-dry-run @@ -190,19 +192,17 @@ jobs: needs: [checks, app-all-sdks-tests, app-tests-shards, app-less-tests, deploy-dry-run] runs-on: ubuntu-18.04 steps: - - uses: actions/checkout@v2 + - name: ready + run: echo "DONE" deploy-request: if: github.event_name == 'push' needs: [master-green-requirement] runs-on: ubuntu-18.04 - container: menny/ndk_ask:1.13.6 + container: menny/android_base:1.13.6 steps: - uses: actions/checkout@v2 - - uses: ./.github/actions/deploy-request - with: - ref: ${{ github.ref }} - sha: ${{ github.sha }} - api_user_name: ${{ secrets.BOT_MASTER_RW_GITHUB_USERNAME }} - api_user_token: ${{ secrets.BOT_MASTER_RW_GITHUB_TOKEN }} - reports_folder: build/deploy-reports + - name: request-new-deploys + run: | + ./gradlew :deployment:imeOnMasterPush :deployment:addOnsOnMasterPush \ + -PrequestDeploy.sha=${{ github.sha }} -PrequestDeploy.api_user_name=${{ secrets.BOT_MASTER_RW_GITHUB_USERNAME }} -PrequestDeploy.api_user_token=${{ secrets.BOT_MASTER_RW_GITHUB_TOKEN }} diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index f44c86db2..c4f92dfdc 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -22,13 +22,6 @@ jobs: with: name: github_object path: build/github_object - - uses: ./.github/actions/deploy-status - with: - deployment_id: ${{ github.event.deployment.id }} - state: in_progress - environment: ${{ github.event.deployment.environment }} - api_user_name: ${{ secrets.BOT_MASTER_RW_GITHUB_USERNAME }} - api_user_token: ${{ secrets.BOT_MASTER_RW_GITHUB_TOKEN }} - name: setup run: | ./scripts/ci/ci_setup.sh @@ -37,29 +30,25 @@ jobs: mkdir -p ime/app/build/outputs/mapping || true - uses: ./.github/actions/deploy with: - deploy_target: ${{ github.event.deployment.environment }} + deployment_id: ${{ github.event.deployment.id }} + deployment_environment: ${{ github.event.deployment.environment }} + deployment_task: ${{ github.event.deployment.task }} crash_report_email: ${{ secrets.ANYSOFTKEYBOARD_CRASH_REPORT_EMAIL }} keystore_url: ${{ secrets.ANYSOFTKEYBOARD_KEYSTORE_URL }} keystore_password: ${{ secrets.ANYSOFTKEYBOARD_KEYSTORE_PASSWORD }} keystore_key_password: ${{ secrets.ANYSOFTKEYBOARD_KEYSTORE_KEY_PASSWORD }} publish_service_account_creds_url: ${{ secrets.PUBLISH_CERT_FILE_URL }} publish_service_account: ${{ secrets.PUBLISH_APK_SERVICE_ACCOUNT_EMAIL }} - - uses: ./.github/actions/deploy-status - if: success() - with: - deployment_id: ${{ github.event.deployment.id }} - state: success - environment: ${{ github.event.deployment.environment }} - api_user_name: ${{ secrets.BOT_MASTER_RW_GITHUB_USERNAME }} - api_user_token: ${{ secrets.BOT_MASTER_RW_GITHUB_TOKEN }} - - uses: ./.github/actions/deploy-status + api_user: ${{ secrets.BOT_MASTER_RW_GITHUB_USERNAME }} + api_token: ${{ secrets.BOT_MASTER_RW_GITHUB_TOKEN }} + - name: status-failure if: failure() + run: ./.github/actions/deploy/status-request.sh "${{ github.event.deployment.id }}" "${{ github.event.deployment.environment }}" "failure" "${{ secrets.BOT_MASTER_RW_GITHUB_USERNAME }}" "${{ secrets.BOT_MASTER_RW_GITHUB_TOKEN }}" + - uses: actions/upload-artifact@v1.0.0 + if: always() with: - deployment_id: ${{ github.event.deployment.id }} - state: failure - environment: ${{ github.event.deployment.environment }} - api_user_name: ${{ secrets.BOT_MASTER_RW_GITHUB_USERNAME }} - api_user_token: ${{ secrets.BOT_MASTER_RW_GITHUB_TOKEN }} + name: deploy-logging + path: build-logging - uses: actions/upload-artifact@v1.0.0 with: name: apks diff --git a/.github/workflows/deployment_promote.yml b/.github/workflows/deployment_promote.yml new file mode 100644 index 000000000..b7940f188 --- /dev/null +++ b/.github/workflows/deployment_promote.yml @@ -0,0 +1,21 @@ +name: deployment + +#always run on the default branch: master +on: + schedule: + - cron: '04 04 * * *' + +env: + TERM: dumb + GRADLE_OPTS: "-Dorg.gradle.daemon=false --stacktrace" + +jobs: + promote-alpha: + runs-on: ubuntu-18.04 + container: menny/android_base:1.13.6 + steps: + - uses: actions/checkout@v2 + - name: requets-pre-release-promote + run: | + ./gradlew :deployment:imePromoteMaster :deployment:addOnsPromoteMaster \ + -PrequestDeploy.sha=${{ github.sha }} -PrequestDeploy.api_user_name=${{ secrets.BOT_MASTER_RW_GITHUB_USERNAME }} -PrequestDeploy.api_user_token=${{ secrets.BOT_MASTER_RW_GITHUB_TOKEN }} |
