Build Log #1 - Serversinc x Github

April 14, 2025

šŸ› ļø What I Worked On

This past weekend’s efforts were focused on adding GitHub integrations to ServerSinc. By the end of the first day (it being a 3-day weekend), I had the following shipped:

šŸ” GitHub Signup

Nothing too fancy here—Laravel Socialite handles most of the heavy lifting, and I simply store the GitHub user ID in the database.

I’ll likely phase out email signups soon. It removes the need for a separate flow to connect a GitHub account later, especially if a user decides to create an application from a repository. Which leads me to...

šŸ—ļø Create an Application from a GitHub Repository

This feature required updates across several parts of the codebase.

The UI for creating an application now includes a new option: ā€œBuild from GitHub Repository.ā€
Once selected, users are taken to a new page where they can:

  • Choose a GitHub repository
  • Select a branch (fetched live using Livewire once a repo is selected)

After the application is created, a job is dispatched to the queue to install a GitHub webhook. This hook points to the ServerSinc API and triggers a rebuild whenever new code is pushed.

The whole kit and kaboodle took less than a morning to integrate using Laravel and GitHub’s API. Copilot chipped in here and there, but since I’d built a similar flow in a previous version of ServerSinc, most of it came straight from memory.

šŸš€ Deployments and Deployment History

While the natural next step might’ve been handling incoming webhooks to trigger builds, I decided instead to focus on the Deployments tab under each Application.

This now shows:

  • A list of deployments
  • The ability to trigger a new deployment

The table is powered by Livewire and automatically updates with new deployments using Livewire’s poll attribute.

šŸ”§ Building a Github Repo

This is a big one, with lots of moving parts behind the scenes. I’ll be writing a separate deep-dive article on how this job works and what it actually does under the hood.

āœ… Wins

  • GitHub OAuth integration
  • Created deployments tab with history
  • GitHub repository hooks connected to ServerSinc
  • Triggering builds via BuildNewGithubApp

āš ļø Challenges

  • Switching context between two repos in two different languages—Laravel (for the dashboard) and Node.js (Tugboat). I still occasionally forget syntax šŸ˜…

šŸ’” What I Learned

Don’t over-engineer everything.

In v1 of ServerSinc, I went all in—custom build servers, private Docker registries, the works.

This time, I’m sticking to the mantra:
ā€œWhat’s the simplest way to make this work?ā€
Then iterate from there.

šŸ”œ Next Up

  • Finish the BuildNewGithubApp job
  • Add webhook listener to trigger rebuilds from pushes

Share this post: