Reference

What Changed Between Gefyra v1 and Gefyra v2?

Explore the architectural evolution of Gefyra 2. State-machine driven operator, decoupled BridgeMounts, fine-grained RBAC client management, and Carrier2 proxying.

Gefyra 2 represents a complete architectural rewrite designed for enterprise stability, multi-developer scaling, and decoupled workload interception.


Key Architectural Enhancements

1. State-Machine Driven Operator (kopf + python-statemachine)

Gefyra 1 relied on simple reactive loops that could get stuck in race conditions during rapid pod rollouts. Gefyra 2 rebuilds the cluster operator around a formal asynchronous state engine. Every transition (REQUESTED ➔ INSTALLING ➔ ACTIVE ➔ ROLLING_BACK) is tracked deterministically with automated retry mechanisms and self-healing rollbacks.

2. Three Decoupled Custom Resources

In Gefyra 1, bridging was a monolithic operation. Gefyra 2 decouples operations into three distinct Custom Resources:

  • GefyraClient: Manages developer authentication, dedicated ServiceAccounts, and WireGuard credentials.
  • GefyraBridgeMount: Manages the injection of the Carrier2 proxy sidecar into target Kubernetes workloads.
  • GefyraBridge: Associates an active mount with a specific developer client.

This decoupling allows a workload mount to stay in place while multiple developers connect, disconnect, or swap routes with zero downtime for the underlying pod.

3. Carrier2 High-Performance Proxying

Gefyra 2 replaces the legacy interception daemon with Carrier2, a high-performance proxy written in Rust. Carrier2 supports bidirectional stream proxying, TLS SNI routing, and low-latency packet forwarding between remote cluster pods and local developer containers.

4. Fine-Grained Access Management & Enterprise RBAC

In Gefyra 1, gefyra up assumed cluster-admin access. Gefyra 2 splits operations into:

  • gefyra install: Admin action to deploy operator and Stowaway gateway.
  • gefyra clients create: Platform lead issues client credentials for a specific namespace.
  • gefyra connections connect: Developer connects using scoped ServiceAccount tokens without requiring cluster-admin permissions.

5. Click-Powered TUI & Rich CLI

The Gefyra CLI was completely rewritten using Python's Click framework with Rich console outputs, interactive progress bars, and structured status reports.