A template to get started with building node apps.
Go to file Use this template
Ahmed 63b43b7fee
Some checks failed
Build and Deploy Node App / build-and-deploy (push) Failing after 6s
update readme links
2026-02-20 03:42:47 +05:30
.gitea/workflows update readme and deploy.yaml 2026-02-20 03:29:14 +05:30
.gitignore Initial commit 2026-02-19 21:47:30 +00:00
README.md update readme links 2026-02-20 03:42:47 +05:30

🚀 The CI/CD Magic Template

Welcome to your deployment engine! This repository contains the "magic" .gitea folder that tells our server how to automatically build your website and put it on the internet.

Because modern tools (like Vite, Next.js, or Astro) create their own brand-new folders when you scaffold them, you will not write your code directly inside this template.

Instead, you will create your app normally, and then "inject" the magic folder into it.


🛠️ How to Start a New Project

1. Scaffold your new website Open your terminal and generate your new app (for example, a Vite React app).

pnpm create vite@latest my-new-site -- --template react
cd my-new-site
pnpm install

2. Download this template Open your file explorer, or use another terminal, and clone this template to your computer:

git clone https://git.pynixworld.com/Moody6/node-app-builder-template.git

3. Inject the Magic Open the node-app-builder-template folder you just downloaded. Copy the hidden .gitea folder, and paste it directly into the root your new my-new-site folder. (Important: The .gitea folder must sit right next to your package.json file!)

4. Connect to the Server Go to the Gitea website and create a brand new, empty repository. Then, go back to your my-new-site terminal and run these commands to link them:

git init
git checkout -b dev  # We always start in the Dev environment!
git remote add origin https://git.pynixworld.com/YOUR_USERNAME/YOUR_NEW_REPO.git

5. Launch It! Add your files, commit, and push. The server will take over from here.

git add .
git commit -m "Initial commit with deployment magic"
git push -u origin dev

(Wait about 15 seconds, then check https://builder.pynixworld.com!)


🌍 The Two Worlds (Environments)

This pipeline uses Branches to decide where your website goes.

  • 🛠️ The dev branch (Staging): Pushing to this branch sends your site to https://builder.pynixworld.com. This is your playground. Break things, test new colors, and experiment here!
  • 🌟 The main branch (Production): Pushing to this branch sends your site to https://www.pynixworld.com. This is your official, live portfolio for the world to see.

To push to production, just merge your dev branch into main and push!

git checkout main
git merge dev
git push origin main

🧰 Changing Frameworks?

This pipeline is set for React, SvelteKit, Vue, or Astro right out of the box.

If you decide to try a different framework like Create React App, Next.js, or SvelteKit, you just need to tell the server which folder to look for.

Open .gitea/workflows/deploy.yaml and look for the dist/* folder to match your new framework (like build/* or out/*).