This project demonstrates how to set up a Vue 3 + Vite project using Bun or Node.js, with automated deployment to SSH SFTP VPS using GitHub Actions.
Run locally with Bun:
bun install
bun run dev
Or with npm:
npm install
npm run dev
Automatic deployment is also set up via .github/workflows/deploy.yml. On every push to main, it:
- Installs dependencies
- Runs the build script (to generate
dist
directory) - Upload
dist
directory into target VPS server via SFTP/SSH.
.
├── .github/workflows/deploy.yml # GitHub Actions CI/CD
├── src/ # Vue app source code
├── dist/ # Auto-generated after build
├── index.html
├── vite.config.ts
└── package.json
{
"scripts": {
"dev": "vite",
"build": "vite build",
"preview": "vite preview"
}
}
You need to add some GitHub Actions env variables.
SSH_IP
SSH_PORT
SSH_USERNAME
SSH_PASSWORD
SSH_PATH
Seyyed Ali Mohammadiyeh (Max Base)
🔗 https://github.com/BaseMax
MIT