Setting Up Kubernetes Multi-Cluster Management via Lens IDE

The cluster fleet is growing, and engineers lose time switching between consoles and manual checks. We configure Lens Kubernetes to manage all clusters from a single window — turnkey: unified access profiles, roles, and a clear policy. Time for typical operations is reduced severalfold, while access remains under control.

Our competencies:

Frequently Asked Questions

Latest works

  • Development of a web application for FEEDME
    Development of a web application for FEEDME
    1365
  • Development of an online store for the company FURNORO
    Development of an online store for the company FURNORO
    1330
  • B2B Advance company logo design
    B2B Advance company logo design
    776
  • Development of a web application for Enviok
    Development of a web application for Enviok
    1077
  • AIDER company logo development
    AIDER company logo development
    1022
  • CRM development for Chasseurs
    CRM development for Chasseurs
    1113

Lens Kubernetes: where cluster fleet management breaks

When there are more than five clusters, management stops being work in a single terminal window.

Connection contexts diverge: some engineers keep local copies of the access file, others use overridden environment variables, and no one can say which permissions are active right now.

A common failure is a change applied to the wrong cluster: namespace names match, so the error is noticed only by its consequences.

The second bottleneck is manual operations. Navigating consoles for each cluster takes time, and environment states diverge: an Operator is updated somewhere, while elsewhere the previous revision remains.

Changes made through a cloud web console do not enter version control — on the next deployment they are silently overwritten, and there is no way to restore them.

The third is delayed response to failure. While the on-call engineer goes through dashboards, the problem is already affecting users, and some failures are learned about from user reports rather than monitoring.

The cause is common: the cluster fleet has no unified control panel — neither for status overview nor for repeatable actions.

This is exactly the part that Lens Kubernetes covers: the engineer's workstation sees the entire fleet through imported connection contexts, shows resource usage and events next to resources, and manual operations stop being the only way to fix something. Below we break down how this is configured and where the limits of applicability are.

Lens Kubernetes: what changes for the engineering team

Before a unified panel, working with multiple clusters looked like this: a dozen access configurations, switching contexts in the terminal, and a constant risk of running a command in the wrong environment.

Lens removes this layer — clusters, namespaces, and workloads are visible in one tree, and switching between environments takes one click instead of changing context.

Diagnostic time is reduced because data does not have to be collected piecemeal. Pod logs, events, resource consumption, and the current manifest open next to the object — the engineer sees the cause, not the consequences.

Troubleshooting an incident such as “service not responding” takes minutes, whereas assembling the picture previously took 20–30 minutes.

Observability becomes continuous: node status, pod readiness, and namespace metrics are consolidated into a single view, and a deviation is noticeable before a user reports it.

At the same time, the share of manual operations drops — restart, scaling, and configuration viewing are performed from the interface, without copying commands and re-entering credentials.

A separate effect is that a class of failures related to an incorrectly selected context disappears: the action is applied to an explicitly specified cluster.

Permissions remain manageable: access to clusters and namespaces is inherited from existing roles rather than granted anew manually.

Cluster access options: panel, console, scripts

The access method is chosen along two axes: the size of the cluster fleet and the scope of permissions for each role.

A panel like Lens aggregates contexts in one window: an engineer switches between clusters without manually editing kubeconfig and sees resource status consistently everywhere.

Next comes permissions discipline. Read-only mode provides logs, events, and metrics but prevents accidental edits or deletions. Full access is granted to a narrow group and through separate credentials so actions are recorded in the audit log.

Provider built-in consoles and custom scripts cover specific scenarios, but each has limits of applicability.

Option When suitable Limitations
Panel, read-only On-call engineers, developers, incident investigation No changes; some operations require other permissions
Panel, full access Operations, releases, debugging Requires separate credentials and audit log
Provider built-in consoles One-off checks in one cloud No fleet-wide view, weak action history
Custom scripts Bulk recurring operations and reports Break when API changes, no context or owner

In practice, the modes are combined: read access by default for most, full access on request and for a limited time, scripts for repeatable tasks with a clear owner.

Implementation stages: from cluster fleet audit to handover

Work proceeds sequentially: without inventory, the access scheme is built blind, and failover testing does not produce a reproducible result. Below is the project flow from cluster fleet audit to handover of policies.

  1. Cluster audit. We compile a list of environments: workloads, owners, where images are stored, how backups are configured. We separately record configuration discrepancies and clusters left without an owner.
  2. Access scheme. We describe roles and groups, separate read and change access, and bind permissions to the existing user directory. Access is granted by role, not by personal key — upon employee departure it is closed with one record.
  3. Connection to a unified panel. Clusters are added to Lens as context sources: the team sees all environments in one window, visibility is limited by namespaces — no one gets excess permissions.
  4. Unified policies. Limits, quotas, and network rules are moved into shared templates — a new cluster is deployed by the same scheme, without manually copying settings.
  5. Failover testing. We simulate failure of a node and an entire zone: do workloads restart, does control remain in the panel, how long does recovery take. Weak points are eliminated before handover.
  6. Documentation. We deliver policies for on-call engineers: access granting, diagnostic scenarios, rollback to the previous version.
  7. Handover. We review live incidents with the customer's team and transfer administrator rights — thereafter changes happen without our involvement.

Access policies, roles, and cluster connection profiles

The customer is left not with a configured interface, but with a portable set of artifacts: roles, connection profiles, configurations, and policies.

Everything resides in version control alongside infrastructure manifests, so permission changes go through review just like code changes, rather than “manually in the panel.”

  • Access roles: read, on-call, and release roles, separated by namespaces, with bindings in declarative form.
  • Connection profiles: sets of contexts for production and test clusters, explicitly stating which are read-only and which grant change rights.
  • Workstation configurations: Lens settings files, panel composition, saved views, and the procedure for migrating to a new machine.
  • Access policy: who grants permissions, for what term, how write access to production is approved, and how it is revoked when an employee moves.
  • Connection instructions: procedure for issuing and updating credentials, behavior when they expire, common errors and how to troubleshoot them.
  • Cluster map: list of environments, their purpose, responsible engineers, integration points with monitoring and build systems.
  • Action audit: where operation history is stored, who changed roles and configurations and when, how a report is exported for review.

Such a kit removes dependence on a specific engineer: a new specialist sets up access in one pass through the instructions, and expanding the perimeter goes through review, not verbal agreements.

Case study: dozens of clusters in one window instead of seven consoles

Before: seven consoles and manual navigation

There were seven environments, each with its own panel, its own access file, and its own set of extensions on the on-call engineer's machine.

To assemble the incident picture, the engineer went through environments one by one: switching context, waiting for the pod list, comparing logs. One pass took 25–30 minutes, and shift handover took the same, because the state had to be described in words.

After: one workstation for all clusters

We consolidated all contexts into a single access file, granted permissions through per-environment roles, and arranged environments as separate workspaces in Lens.

The on-call engineer sees the state of all clusters in one window, switching between environments takes 2–3 seconds instead of minutes, and logs and the terminal open in place.

Permissions are separated: view for on-call engineers, changes only for release engineers, and no access to production without confirmation.

What changed in numbers

Incident response time dropped from 25–30 minutes to 6–8: gathering the initial picture is no longer a separate stage. Manual actions during deployment decreased threefold — some checks moved into automated rules rather than the on-call checklist.

Onboarding a new engineer into a shift takes one day instead of three, because access is granted by role, not by a ten-point instruction.

What to do if clusters are already managed through other panels?

A panel is a client to the cluster's API server, not part of it. Permissions are defined by roles and bindings inside the cluster itself, and an interface like Lens only shows what is already permitted.

Therefore there is nothing to migrate between panels: the task is not rebuilding infrastructure but consolidating access.

We start with inventory. We look at which consoles are actually used, who accesses them, which contexts are in access files, and where permissions are granted directly, bypassing groups.

Some such exceptions are usually forgotten — they are consolidated into roles and groups so access does not depend on a specific tool.

Next is parallel operation without downtime. The new panel connects to the same clusters and uses the same roles; old ones continue to work. Teams test the scheme on live tasks: check node status, roll out a release, roll it back, grant access to a namespace. Permission discrepancies are visible immediately, while nothing has been disabled yet.

The phased transition goes team by team: first those who requested a single entry point themselves, then the rest. We agree on the dual-access period in advance, and tools no longer in use are disabled together with their credentials.

We separately close manually granted accesses: we remove them last, after the team confirms everyday tasks are handled in the new scheme. The result is one role list, single sign-on through a corporate identity provider, and access revocation in one place. Clusters are not rebuilt, and teams do not lose a working day.

Technical concerns: access security, rollback, compatibility

Concerns around a cluster management panel boil down to four questions: who sees what, what happens if the workstation is unavailable, how to roll back what was applied, and whether the configuration will survive a spread of versions. We address each in substance.

How are team permissions separated?

Lens is a client to the API server; it does not store its own credentials. Each engineer connects with their own token or certificate, and access is determined by the cluster's role model: namespaces, resource types, permitted actions. Permissions are revoked on the cluster side — the panel does not cache or expand them.

What happens if the panel becomes unavailable?

The panel is not part of the control plane: it does not proxy traffic or store state. Stopping the workstation does not affect workloads — build and delivery pipelines, operators, and the command-line utility continue to work. Recovery is simply reconnecting with the same certificate.

How are changes rolled back?

Objects are described declaratively and stored in version control; the panel only applies repository contents. Rollback is a manifest revert and re-apply, not manual editing in the interface.

Discrepancies introduced manually are visible when comparing the cluster state with the repository before they accumulate.

Are clusters of different versions compatible?

The panel connects several clusters simultaneously, but the set of available operations depends on the API version of a specific cluster: some capabilities simply do not appear.

We fix the supported version matrix before connection and plan updates with it in mind, so the interface does not diverge from the cluster's actual capabilities.

Let's discuss the cluster fleet: what to send for assessment

To come back with a work estimate and implementation plan rather than general statements, we need your actual landscape. Below is the minimum set of source data: from it we assemble a cluster diagram, identify bottlenecks, and break the work into stages. Some items are covered by one conversation, some by an export from your management panels.

  • Cluster list: cloud, own servers, or hybrid; how many environments; versions in the current branch.
  • Connection methods: kubeconfig files or service accounts with read permissions and the procedure for issuing them through your security service.
  • Network connectivity: private networks, bastion, VPN, availability of the management panel from engineers' workstations.
  • Access model: who owns the clusters, which namespaces and roles are used, how access is granted and revoked.
  • Current management: what you use now, how many engineers connect, and how contexts are passed between teams.
  • Workload inventory: number of applications and environments, criticality, availability requirements, maintenance windows.
  • Bottlenecks: what gets in the way today — manual context switching, lack of fleet-wide visibility, fragmented permissions.

This is enough to propose a unified management scheme: a workspace in Lens, cluster groups, roles, and access separation by team.

In response, we send a cluster diagram, a stage-by-stage work estimate, and an implementation plan with the order of actions and areas of responsibility — then we discuss timelines.