A simple web UI to manage and automatically pull updates for your Git repositories.
-
Install dependencies and build the frontend:
npm install npm run build
-
Create a
.envfile in the root of the project and add a webhook secret:WEBHOOK_SECRET=your-super-secret-token -
Start the backend server:
npm start
-
Start the frontend development server: In a new terminal, run:
cd frontend npm run dev
The application will be running at http://localhost:5173.
To receive webhooks from services like GitHub on your local machine, you need a way to expose your local server to the internet. ngrok is a great tool for this.
-
Download and install ngrok from ngrok.com.
-
With your local server running (
npm start), open a new terminal and start ngrok to create a public tunnel to your local port 3000:ngrok http 3000
-
Ngrok will give you a public "Forwarding" URL (it will look something like
https://<random-string>.ngrok.io). -
Go to your repository's settings on GitHub, navigate to Webhooks, and click Add webhook.
- Payload URL: Paste the ngrok URL and add the
/api/webhookpath. For example:https://<random-string>.ngrok.io/api/webhook. - Content type: Set this to
application/json. - Secret: Enter the same secret you defined in your
.envfile forWEBHOOK_SECRET. - Which events would you like to trigger this webhook? Select "Just the push event."
- Payload URL: Paste the ngrok URL and add the
-
Click Add webhook. Now, whenever you push a change to your repository, GitHub will send a
pushevent to your local server via ngrok, and the application will automatically pull the changes.