← All posts

Vibe Coding Meets Production: Guardrails Every Team Needs

By MergeRequest · · DevSecOps

There is a new phrase going around: “vibe coding.” The idea is simple. You describe what you want in plain language, let the AI write the code, and keep going as long as it seems to work. You do not read every line. You follow the vibe.

For a weekend project or a throwaway prototype, this is great. We have used it ourselves to test an idea in an afternoon. The trouble starts when the prototype quietly becomes the product. Code that nobody on the team has read is now handling customer data.

You do not have to ban the approach. You do have to put some guardrails between the vibe and production.

1. Decide Where It Is Allowed

Be explicit. Prototypes, internal tools and spikes are fine places to move fast. Payment flows, authentication and anything touching personal data deserve a human who understands every line. Write this down so nobody has to guess.

2. Every Change Still Gets Reviewed

AI-written code goes through the same pull request process as everything else. The author of the pull request owns the change, whoever or whatever typed it. If they cannot explain what it does, it is not ready to merge.

3. Protect the Main Branch

Branch protection is not new, but it matters more now. Require passing checks and at least one approval before merge. Do not let anyone, human or tool, push straight to main.

4. Let the Pipeline Do the Boring Checks

Automated checks do not get tired and do not get carried away by a good demo. At a minimum, run:

  • Static analysis and linting on every pull request
  • Dependency scanning, so a made-up or vulnerable package does not slip in
  • Secret scanning, so keys pasted into a prompt do not end up in the repo
  • The full test suite, with a coverage threshold for new code

5. Keep Secrets Out of Prompts

It is easy to paste an error message with a connection string in it into a chat window. Give developers a safe way to work: local environment files that are never committed, short-lived credentials and clear rules about what may be shared with which tool.

6. Watch for Code Nobody Understands

The real long-term risk is not a single bug. It is a codebase that works but that no one can explain. Ask for small pull requests. Ask for tests with each change. Ask the author to describe the approach in their own words in the description.

Conclusion

Vibe coding is a fast way to explore an idea, and there is nothing wrong with that. Production is a different place with different rules. With clear boundaries, protected branches and a pipeline that checks every change, you can enjoy the speed without betting the business on code nobody has read. This is exactly what a good DevSecOps practice is for.

Let’s talk about a project, collaboration or an idea you may have

ACCELERATING INNOVATION SINCE 2021 ·

Contact form