This repository has been archived by the owner on Aug 23, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
72 lines (56 loc) · 1.86 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: Release
on:
release:
types: [published]
workflow_dispatch:
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.13
- name: Use Node.js v14.x
uses: actions/[email protected]
with:
node-version: 14.x
- name: Check out code
uses: actions/checkout@v2
- name: Setup protoc
uses: arduino/[email protected]
- name: Install protoc-gen-go
run: go get -u google.golang.org/protobuf/cmd/protoc-gen-go
- name: Install statik command line tool
run: go get -u github.com/rakyll/statik
- uses: actions/[email protected]
with:
path: ${{ github.workspace }}/.next/cache
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}
- uses: bahmutov/npm-install@v1
- name: Build protocol buffers code
run: bash ./tools/protoc.sh
- name: Run build script
run: bash ./tools/build.sh
- name: Upload Release Asset
if: ${{ github.event_name == 'release' }}
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./build/backend
asset_name: server_linux_x64
asset_content_type: application/octet-stream
- name: Install repl.it CLI
run: npm i -g replit
- name: Set up repl.it CLI
run: replit auth -k "$TOKEN" && replit local 43df7835-2bf0-45ad-9ef9-6b6e1f58dffe
env:
TOKEN: ${{ secrets.REPLIT_TOKEN }}
- name: Deploy to Repl.it
run: replit bulk \
cp build/backend repl:murdermystery -- \
run --restart