Skip to content

Commit

Permalink
Added GitHub Action to deploy website on server on push
Browse files Browse the repository at this point in the history
  • Loading branch information
FlyingDR committed Aug 7, 2024
1 parent af9a772 commit 15c7e1a
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
on: push
name: Deploy website on push
jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest
steps:
- name: Get latest code
uses: actions/checkout@v4

- name: Use Node.js 20
uses: actions/setup-node@v4
with:
node-version: '20'

- name: NPM install
uses: bahmutov/npm-install@v1

- name: Build Project
run: npm run build

- name: Deploy on server
uses: wlixcc/SFTP-Deploy-Action@v1.2.4
with:
server: vipassana.ru
username: anapana
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}
local_path: './out/*'
remote_path: '/home/anapana/web'
sftpArgs: '-o ConnectTimeout=5'

0 comments on commit 15c7e1a

Please sign in to comment.