Skip to content

Merge pull request #45 from Cumulo/dependabot/npm_and_yarn/ws-7.5.10 #57

Merge pull request #45 from Cumulo/dependabot/npm_and_yarn/ws-7.5.10

Merge pull request #45 from Cumulo/dependabot/npm_and_yarn/ws-7.5.10 #57

Workflow file for this run

name: Upload Assets
on:
pull_request: {}
push:
branches:
- master
jobs:
upload-assets:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: docker://timbru31/java-node:latest
- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- uses: actions/cache@v1
name: Cache node modules of yarn
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Cache Clojars
uses: actions/cache@v1
env:
cache-name: cache-clojars
with:
path: ~/.m2/repository
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('shadow-cljs.edn') }}
restore-keys: |
${{ runner.os }}-clojars
- run: yarn && yarn build
name: Build web assets
- run: mkdir -p dist-server && mv dist/server.js dist-server && cp package.json dist-server/
name: Copy server scripts
- name: Upload web assets
id: deploy
uses: Pendect/[email protected]
env:
DEPLOY_KEY: ${{secrets.rsync_private_key}}
with:
flags: '-avzr --progress'
options: ''
ssh_options: ''
src: 'dist/*'
dest: '[email protected]:/web-assets/repo/${{ github.repository }}'
- name: Display status from deploy
run: echo "${{ steps.deploy.outputs.status }}"
- name: Upload server script
id: deploy-server
uses: Pendect/[email protected]
env:
DEPLOY_KEY: ${{secrets.rsync_private_key}}
with:
flags: '-avzr --progress'
options: ''
ssh_options: ''
src: 'dist-server/*'
dest: '[email protected]:/servers/workflow'
- name: Display status from deploy
run: echo "${{ steps.deploy-server.outputs.status }}"