Skip to content

Commit

Permalink
Action updated for correct deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
haslo committed Aug 17, 2024
1 parent 9de981f commit 3e18c89
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 33 deletions.
33 changes: 0 additions & 33 deletions .github/workflows/deploy_to_ftp.yml

This file was deleted.

35 changes: 35 additions & 0 deletions .github/workflows/deploy_with_scp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: 🚀 Deploy website on push
on:
push:
branches:
- main

jobs:
build-and-deploy:
name: 🎉 Build and Deploy
runs-on: ubuntu-latest

steps:
- name: 🚚 Checkout code
uses: actions/checkout@v2

- name: 🛠 Setup Node.js
uses: actions/setup-node@v2
with:
node-version: '16'

- name: 📦 Install dependencies
run: npm ci

- name: 🔨 Build project
run: npm run build

- name: 📂 Deploy to server
uses: appleboy/scp-action@master
with:
host: sl2201.web.hostpoint.ch
username: bkserfa
key: ${{ secrets.SSH_DEPLOY_KEY }}
source: "build/*"
target: "/home/bkserfa/www/haslo.ch"
strip_components: 1

0 comments on commit 3e18c89

Please sign in to comment.