Skip to content

Commit

Permalink
Deploy action
Browse files Browse the repository at this point in the history
  • Loading branch information
pedelgado authored May 6, 2024
1 parent 85de190 commit e63ff28
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 2 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs

name: Node.js CI

on:
push:
branches: [ "main" ]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [14.x, 16.x, 18.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm run build

- name: Copy result in server
uses: easingthemes/ssh-deploy@main
with:
SSH_PRIVATE_KEY: ${{ secrets.OCEBOT_PRIVATE_SSH_KEY }}
ARGS: "-rlgoDzvc -i --delete"
SOURCE: "dist/"
REMOTE_HOST: ${{ secrets.OCEBOT_HOST }}
REMOTE_USER: ${{ secrets.OCEBOT_HOST_USER }}
TARGET: ${{ secrets.KT_HOST_PATH }}
EXCLUDE: ""
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@
"type": "module",
"scripts": {
"dev": "vite",
"build": "vite build",
"build": "npm run tw-build && vite build",
"lint": "eslint . --ext js,jsx --report-unused-disable-directives --max-warnings 0",
"preview": "vite preview",
"tw": "npx tailwindcss -i ./src/input.css -o ./src/output.css --watch"
"tw-watch": "npx tailwindcss -i ./src/input.css -o ./src/output.css --watch",
"tw-build" : "npx tailwindcss -i ./src/input.css -o ./src/output.css --minify"
},
"dependencies": {
"lightweight-charts": "^4.0.1",
Expand Down

0 comments on commit e63ff28

Please sign in to comment.