-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
config: update workflows for deploying
- Loading branch information
Showing
8 changed files
with
7,403 additions
and
35,759 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
name: Build & Deploy | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
|
||
pull_request: | ||
branches: [ "main" ] | ||
|
||
jobs: | ||
build-and-deploy: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [18.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Use Node ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
|
||
- name: Get Yarn cache directory | ||
id: yarn-cache-dir | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
|
||
- uses: actions/cache@v2 | ||
id: yarn-cache | ||
with: | ||
path: ${{ steps.yarn-cache-dir.outputs.dir }} | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
- name: Install dependencies | ||
run: yarn install | ||
|
||
- run: yarn build | ||
|
||
- uses: a7ul/[email protected] | ||
with: | ||
command: c | ||
cwd: "./" | ||
files: | | ||
dist/ | ||
captain-definition | ||
outPath: deploy.tar | ||
|
||
- name: Deploy App to CapRover | ||
uses: caprover/[email protected] | ||
with: | ||
server: '${{ secrets.CAPROVER_SERVER }}' | ||
app: '${{ secrets.APP_NAME }}' | ||
token: '${{ secrets.APP_TOKEN }}' |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"schemaVersion": 2, | ||
"dockerfileLines": [ | ||
"FROM socialengine/nginx-spa:latest", | ||
"COPY ./dist /app" | ||
] | ||
} |
Oops, something went wrong.