forked from wikiadventure/wikiadventu.re
-
Notifications
You must be signed in to change notification settings - Fork 0
64 lines (62 loc) · 2.55 KB
/
CleverCloudDeploy.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
name: Compile and deploy to Clever Cloud
on:
workflow_dispatch:
jobs:
build:
env:
ADMIN_PASSWORD: ${{secrets.ADMIN_PASSWORD}}
TWITCH_BOT_USERNAME: ${{secrets.TWITCH_BOT_USERNAME}}
TWITCH_BOT_PASSWORD: ${{secrets.TWITCH_BOT_PASSWORD}}
TWITCH_CLIENT_ID: ${{secrets.TWITCH_CLIENT_ID}}
TWITCH_CLIENT_SECRET: ${{secrets.TWITCH_CLIENT_SECRET}}
TWITCH_REDIRECT_URL: ${{secrets.TWITCH_REDIRECT_URL}}
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- uses: actions/checkout@v2
#- name: Tell the player of incoming update
#run: curl -u ":${{secrets.ADMIN_SECRET}}" https://wiki-adventure.herokuapp.com/api/announce --data "New update is coming your party will be interrupted in few minute."
- continue-on-error: true
run: |
git config --global user.email '[email protected]'
git config --global user.name 'Sacramentix'
- name: Setup Node.js environment
uses: actions/[email protected]
- name: GitHub Action for npx
uses: mikeal/[email protected]
- name: Install lix
run: |
cd back
npm i
- name: Build backend
run: |
cd back
npx haxe node.hxml
- name: Install frontend lib
run: |
cd front
npm i
- name: Build frontend
run: |
cd front
npm i @quasar/cli
npx quasar build -m pwa
- name: Install Clever Tools and deploy the app
run: |
cd bin
git init
git add *
git commit -m "Deploy..."
npm i --no-save clever-tools
npx clever login --token ${{ secrets.CLEVER_TOKEN }} --secret ${{ secrets.CLEVER_SECRET }}
npx clever link ${{secrets.CLEVER_APP_ID}}
npx clever env set CLEVER_ADMIN_PASSWORD ${{secrets.ADMIN_PASSWORD}}
npx clever env set CLEVER_TWITCH_BOT_USERNAME ${{secrets.TWITCH_BOT_USERNAME}}
npx clever env set CLEVER_TWITCH_BOT_PASSWORD ${{secrets.TWITCH_BOT_PASSWORD}}
npx clever env set CLEVER_TWITCH_CLIENT_ID ${{secrets.TWITCH_CLIENT_ID}}
npx clever env set CLEVER_TWITCH_CLIENT_SECRET ${{secrets.TWITCH_CLIENT_SECRET}}
npx clever env set CLEVER_TWITCH_REDIRECT_URL ${{secrets.TWITCH_REDIRECT_URL}}
npx clever env set CLEVER_TOKEN ${{ secrets.CLEVER_TOKEN }}
npx clever env set CLEVER_SECRET ${{ secrets.CLEVER_SECRET }}
npx clever deploy --force