Skip to content

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.

License

Notifications You must be signed in to change notification settings

BaseMax/vuejs-cicd-deploy-sftp-ssh

Repository files navigation

🚀 Vue.js CI/CD Deployment on SFTP SSH (via GitHub Actions)

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.


📦 Tech Stack


🧪 Development

Run locally with Bun:

bun install
bun run dev

Or with npm:

npm install
npm run dev

▶ GitHub Actions CI/CD

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.

📁 Directory Structure

.
├── .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 in package.json

{
  "scripts": {
    "dev": "vite",
    "build": "vite build",
    "preview": "vite preview"
  }
}

🔐 Notes

You need to add some GitHub Actions env variables.

  • SSH_IP
  • SSH_PORT
  • SSH_USERNAME
  • SSH_PASSWORD
  • SSH_PATH

👤 Author

Seyyed Ali Mohammadiyeh (Max Base)

📬 maxbasecode@gmail.com

🔗 https://github.com/BaseMax

🪪 License

MIT

About

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.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published