saharbarak.dev

dop: Configure OAuth Once, Never Touch It Again

Open SourceDeveloper ToolsBashOAuth

dop: Configure OAuth Once, Never Touch It Again

4 min read2 views

dop: Configure OAuth Once, Never Touch It Again

Zero-config OAuth proxy for local development. Configure Google OAuth once and never touch it again. Pure bash, no Docker, no Node.

dop: Configure OAuth Once, Never Touch It Again

How I built a zero-config OAuth proxy for local development in pure bash — no Docker, no Node, just install and run.

The Problem Every Developer Knows

You're deep in focus, building a new feature. You spin up your dev server on port 3001 because port 3000 is taken. You click "Login with Google."

Error: redirect_uri_mismatch

Sound familiar?

Every time your local dev app runs on a different port, you have to:

  1. Go to Google Cloud Console
  2. Update OAuth redirect URIs
  3. Wait for propagation
  4. Lose 30 minutes of your life

Multiply this by every developer on your team, every project, every time someone runs on a different port. It's insane.

The Solution: One Port to Rule Them All

What if you could configure Google OAuth once — with http://localhost:3000/auth/google/callback — and never touch it again?

That's exactly what dop (Dev OAuth Proxy) does.

bash

Your app on port 3001? Works. Port 4000? Works. Port 8080? Works.

All OAuth callbacks flow through port 3000, and dop routes them to wherever your app is actually running.

How It Works

plain text
  1. Proxy listens on port 3000 (your configured OAuth callback port)
  2. Routes requests by path prefix to your actual apps
  3. OAuth callbacks are intercepted and routed to the originating app
  4. Apps run on any port — the proxy handles everything

Why Pure Bash?

I wanted something that:

  • Just works — no runtime dependencies beyond what macOS ships with
  • Installs in seconds — not minutes of npm/Docker setup
  • Uses minimal resources — it's a proxy, not a Kubernetes cluster
  • Is easy to understand — read the source, fork it, fix it

The result: ~500 lines of bash that handles everything.

Features That Actually Matter

Auto-Detect Running Apps

bash

Live Dashboard

bash

Team Sharing

Commit a .dop.yaml to your repo:

yaml

Team members just run:

bash

No more "what port are you running on?" Slack messages.

Installation

bash

The Commands

| Command | Description | |---------|-------------| | dop init | Initialize configuration | | dop add | Add an app | | dop scan | Auto-detect running apps | | dop dashboard | Live status view | | dop start | Start the proxy | | dop sync | Load team config from .dop.yaml | | dop doctor | Check system requirements |

OAuth Providers Supported

  • Google: http://localhost:3000/auth/google/callback
  • GitHub: http://localhost:3000/auth/github/callback
  • GitLab: http://localhost:3000/auth/gitlab/callback
  • Auth0: http://localhost:3000/auth/auth0/callback
  • Generic: http://localhost:3000/oauth/callback

Open Source

The entire project is MIT licensed and available on GitHub:

GitHub: https://github.com/SaharBarak/dev-oauth-proxy Homebrew: https://github.com/SaharBarak/homebrew-tap

PRs welcome. Keep it simple. Keep it bash.

Try It

If you're tired of the redirect_uri_mismatch dance, give dop a shot:

bash

Configure Google OAuth once with http://localhost:3000/auth/google/callback and never touch it again.

0

Hold to clap more

Enjoyed this article?

Subscribe to get notified when I publish new articles about engineering, AI, and building products.

S

Sahar Barak

Engineer, researcher, and builder. Writing about AI, identity systems, clean energy, and the future of software.

Discussion

Sign in to join the conversation