[Issue-2276] Update backup/restore methods on web-runner #517
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Master | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
master: | |
if: "! startsWith(github.event.head_commit.message, '[CI Skip]')" | |
strategy: | |
matrix: | |
step: ['build:release'] | |
name: ${{ matrix.step }} | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
token: ${{ secrets.GH_PAT }} | |
- name: ${{ matrix.step }} | |
env: | |
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} | |
GH_PAT: ${{ secrets.GH_PAT }} | |
GH_RELEASE_GITHUB_API_TOKEN: ${{ secrets.GH_PAT }} | |
GH_RELEASE_FILES: master-build.zip,master-src.zip | |
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
TRANSAK_API_KEY: ${{ secrets.TRANSAK_API_KEY }} | |
COINBASE_PAY_ID: ${{ secrets.COINBASE_PAY_ID }} | |
BRANCH_NAME: ${{ github.ref_name }} | |
run: | | |
yarn install --immutable | grep -v 'YN0013' | |
yarn ${{ matrix.step }} | |
- name: Upload to Build to Nextcloud | |
id: nextcloud_upload | |
uses: trympet/nextcloud-artifacts-action@v2 | |
with: | |
name: 'master-build.zip' | |
path: 'master-build.zip' | |
nextcloud-url: 'https://file.cdmteck.com' | |
nextcloud-username: ${{ secrets.NEXTCLOUD_USERNAME }} | |
nextcloud-password: ${{ secrets.NEXTCLOUD_PASSWORD }} | |
- name: Deploy Webrunner to Netlify | |
id: netlify_deployment | |
uses: nwtgck/[email protected] | |
with: | |
publish-dir: './packages/web-runner/build' | |
production-branch: master | |
github-token: ${{ secrets.GH_PAT }} | |
deploy-message: ${{ github.event.head_commit.message }} | |
enable-pull-request-comment: true | |
enable-commit-comment: true | |
env: | |
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }} | |
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_WEB_RUNNER_SITE_ID }} | |
timeout-minutes: 1 | |
- name: Notify to Discord | |
uses: sarisia/actions-status-discord@v1 | |
if: always() | |
with: | |
webhook: ${{ secrets.DISCORD_WEBHOOK }} | |
status: ${{ job.status }} | |
username: Extension Worker | |
title: ${{ github.workflow }} | |
description: | | |
Master is completed. | |
- Extension: ${{ steps.nextcloud_upload.outputs.SHAREABLE_URL }} | |
- Web-runner: ${{ steps.netlify_deployment.outputs.deploy-url }} |