How to Configure Argo Workflows RBAC

Published
Length
3 min read

Luis Felipe Dias

All posts

Setting up argo workflows rbac controls which users and pods can run or edit jobs. You set it up by linking identity provider groups to Kubernetes service accounts and roles. Without strict rules, any person or pod in a namespace can trigger heavy jobs. A clear role setup limits who can start, stop, or view your pipelines. How argo workflows rbac works in your cluster Argo Workflows relies on native Kubernetes roles to check user and pod permissions. It separates permissions into three disti

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

Setting up argo workflows rbac controls which users and pods can run or edit jobs. You set it up by linking identity provider groups to Kubernetes service accounts and roles.

Without strict rules, any person or pod in a namespace can trigger heavy jobs. A clear role setup limits who can start, stop, or view your pipelines.

How argo workflows rbac works in your cluster

Argo Workflows relies on native Kubernetes roles to check user and pod permissions. It separates permissions into three distinct layers across your cluster.

First, the main controller needs a service account to watch and manage pod states. Second, the server needs its own rules to show the user interface and take requests. Third, each workflow run uses a dedicated service account to execute its steps.

When a person logs in through single sign-on, the server checks their group claims. The server then maps those group claims to a local Kubernetes service account. You add annotations to that service account to define matching rules for groups. A rule checks if the user belongs to a specific team in your identity tool. If the rule matches, the user gets the permissions of that service account.

Many teams make the mistake of using the default service account for task runs. In many clusters, this account has too many permissions or none at all. Instead, create a fresh service account for each project or team namespace.

Setting safe defaults for workflow service accounts

Good security starts with giving each role the smallest set of permissions possible. Most developers only need to view logs and submit templates in their own namespace. They do not need cluster-wide rules or the right to edit Kubernetes secrets.

You should split human users into viewer, runner, and admin roles per namespace. Viewers only get read verbs on workflow resources and pod logs. Runners get read verbs plus permission to create and delete job runs. Admins can change templates, cron schedules, and namespace settings.

Access Request Workflows + Azure RBAC: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Pay close attention to the service accounts that run the actual workflow pods. A pod service account only needs to report its task status back to the controller. It should not have permission to start new workflows or read other secrets. If a task builds code or moves data, scope its role to those exact resources.

When several teams share one cluster, keep their resources in separate namespaces. Bind roles at the namespace level rather than the whole cluster level. This stops a broken job in one team from hurting another team.

Checking rules and closing static permission gaps

After you apply your roles, you must test that the rules work as planned. You can test permissions using standard Kubernetes permission checks for each service account. Check both what the account can do and what it cannot do.

Turn on Kubernetes audit logs to see which service accounts run jobs each day. Audit logs show when a user maps to a role and starts a job. Yet native single sign-on mappings often hide which human triggered a shared service account. Multiple engineers in the same group all map to the exact same cluster account.

Static role files also leave big gaps after a session starts. Once a user has permission to run a workflow, they can pass any input values. Static Kubernetes roles cannot inspect the payload inside a job request. They also cannot mask sensitive fields like emails, phone numbers, or card numbers in logs. If a job prints national IDs to standard output, any viewer can see those values. Teams need stronger controls to tie every action back to a specific person.

Add runtime guardrails and masking beside your databases and APIs

Login rules, role grants, and CI checks govern who connects to your stack. Yet any allowed script, engineer, or AI agent still runs commands with the full scope of its role. For workloads on Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes, SSH, or internal HTTP services, hoop.dev sits beside the service as an open-source proxy, a sidecar for your database or API.

Before a query runs, hoop.dev guardrails check the statement against your rules. An AI Analyzer you configure can score intent or hold risky calls for human review. Next, hoop.dev data masking rewrites sensitive fields in responses, and each verdict is logged per listener. Explore the MIT-licensed project on GitHub.

Frequently asked questions

What is the difference between server roles and executor roles?

Server roles control what human users can see and click in the user interface. Executor roles control what the running task pods can do inside the Kubernetes cluster.

How do I map single sign-on groups to Kubernetes roles?

You add rule annotations to a Kubernetes service account that check identity token groups. The server reads these rules at login and picks the highest ranked service account.

Why do my workflow pods fail with permission errors on startup?

The pod service account lacks permission to update task results or patch pod state. Bind a basic role to that service account so it can report task status.

The query runs. The emails stay hidden.