← Archive·Filed under Ocheverse
11·11·26
Ocheverse · EngineeringWednesday, 11 November 202611 min read

The Engineering Standards Nobody Talks About: Your CI/CD Pipeline Is Production Infrastructure. Start Treating It That Way

The Engineering Standards Nobody Talks About — Episode 01

There is something I’ve noticed about how engineering teams approach infrastructure security.

We spend a ridiculous amount of time securing production environments. We configure IAM policies, isolate workloads, restrict network access, implement monitoring, and debate whether our applications should run on Kubernetes, ECS, or virtual machines.

Then we turn around and give a CI/CD pipeline enough permissions to deploy into those environments, sometimes with very little consideration for the security of the system doing the deploying.

Omo, how does that make sense?

Your production infrastructure might be protected by multiple layers of security, but if a compromised pipeline can deploy arbitrary code into it, how secure is it really?

That’s why I think we need to stop treating CI/CD as merely a developer productivity tool.

Your CI/CD pipeline is part of your production infrastructure, whether you acknowledge it or not.

And it should be governed accordingly.

We’ve Been Looking at the Wrong Boundary

When we talk about production security, we often focus on the applications and infrastructure running in production.

Who can access the database? Which services are publicly exposed? Are secrets encrypted? Do workloads have excessive IAM permissions?

All important questions.

But there’s another question I think deserves equal attention.

Who or what has the authority to change production?

Because that’s where CI/CD comes in.

A deployment pipeline can build application artifacts, access package registries, retrieve credentials, publish container images, modify cloud resources, and release software into production.

Depending on how it’s configured, it might also have access to infrastructure state files, internal networks, and other sensitive systems.

Essentially, we’ve built an automation platform that can exercise significant control over our infrastructure.

And somehow, we still sometimes treat it as a few YAML files sitting inside .github/workflows.

The YAML isn’t the problem.

The problem is the amount of trust we place in everything that executes it.

A compromised application is dangerous. A compromised pipeline with broad deployment permissions can potentially affect multiple applications, environments, or services.

That distinction should fundamentally change how we design CI/CD systems.

Your Build Runner Is Not Just a Machine Running Commands

Let’s talk about runners.

I understand why engineering teams choose self-hosted runners. They offer control over execution environments, custom tooling, potentially better performance for certain workloads, and access to private infrastructure.

In some organizations, they’re entirely justified.

But persistent self-hosted runners introduce security considerations that teams sometimes underestimate.

Think about what happens when a build executes.

It checks out source code, downloads dependencies, runs scripts, builds artifacts, and potentially interacts with cloud services.

You’re executing code from multiple sources, some of which you don’t directly control.

What happens if a dependency is compromised?

What happens if a workflow executes untrusted code?

What happens if a runner retains sensitive information between jobs?

Now consider that the same machine might execute workflows for different projects, each with different security requirements.

A runner that has accumulated credentials, filesystem state, or access to internal systems can become a much more attractive target than a temporary build environment.

This is why I’m increasingly convinced that ephemeral execution should be the default consideration for CI/CD architecture.

Provision an isolated environment for a job, execute the workload, preserve the necessary logs and artifacts, and destroy the execution environment afterward.

No unnecessary persistence. No casually sharing execution environments across unrelated trust boundaries.

But let’s not pretend ephemeral runners solve everything.

If malicious code can access credentials during an active job, it doesn’t need the runner to survive for another twenty-four hours.

It can steal what it needs immediately.

So the standard shouldn’t simply be “use ephemeral runners.”

It should be:

Treat every build execution as potentially untrusted, and design its permissions and environment accordingly.

That means separating build and deployment responsibilities, limiting secrets exposure, isolating workloads, and ensuring that a compromised job cannot automatically become a compromised production environment.

Stop Giving CI More Permissions Than It Needs

One of the most consequential CI/CD design decisions is how a pipeline authenticates to cloud infrastructure.

Traditionally, many teams have relied on long-lived access keys stored as repository or organization secrets.

It works. It’s relatively straightforward. And it’s the sort of solution that can quietly survive for years because nobody wants to touch a working deployment pipeline.

But long-lived credentials create unnecessary exposure.

If they’re compromised, an attacker may retain access until the credentials are revoked, expire, or are otherwise invalidated.

For supported platforms, I would rather see CI/CD systems use workload identity federation, such as OpenID Connect, to obtain temporary credentials.

For example, GitHub Actions can authenticate to AWS through OIDC and assume an appropriately configured IAM role.

That avoids distributing permanent AWS access keys to every pipeline that needs to deploy something.

However, temporary credentials alone are not enough.

The role’s trust policy must restrict which repositories, branches, environments, or approved workflows can assume it.

Its permissions should also be scoped to the exact deployment responsibilities required.

A pipeline building a Docker image does not automatically need permission to modify production infrastructure.

A pipeline running unit tests certainly doesn’t need access to production secrets.

And a deployment job shouldn’t receive unrestricted administrative access simply because configuring granular permissions takes more effort.

Convenience is not an acceptable long-term identity strategy.

Build Once. Promote What You’ve Tested.

Here’s another practice I’d like engineering teams to take more seriously.

Artifact promotion.

In some pipelines, the application is rebuilt separately for development, staging, and production.

At first glance, this seems reasonable. Every environment gets a fresh build.

But it introduces an important question.

Are you deploying the exact artifact you tested, or are you deploying something that was built again afterward?

Those aren’t necessarily the same thing.

Dependencies can change, base images can be updated, build environments can differ, and external package repositories can produce unexpected results.

A more defensible release process builds an artifact once, verifies it, and promotes that same immutable artifact through the appropriate environments.

For containerized applications, that can mean deploying a specific image digest rather than relying on mutable tags.

Teams can also introduce software bills of materials, artifact signing, build provenance, and verification controls depending on their security requirements.

Not every startup needs the most sophisticated software supply-chain platform available.

But every engineering organization should be able to answer a basic question:

Can we demonstrate that the software running in production is the software we intended to build, test, approve, and release?

If the answer is no, there’s a gap worth addressing.

A Successful Deployment Isn’t the Same Thing as a Safe Deployment

Another assumption I think we need to challenge is that a green pipeline means a successful release.

A workflow completing without errors tells you something about the execution of that workflow.

It doesn’t necessarily tell you whether the application is healthy, whether customers can use it, or whether the deployment introduced a performance regression.

I’ve always found it interesting how much effort teams put into automating deployment without applying the same attention to validation and recovery.

If your pipeline can deploy to production, it should also support a clear process for detecting failure and initiating recovery.

Who owns the release?

What health signals determine whether deployment succeeded?

Can the previous application version be restored safely?

What happens if a database migration isn’t backward compatible?

Who gets notified if the deployment creates an incident?

These are not questions we should first be answering while production is down.

And rollback isn’t always as simple as redeploying an older image. Database changes, message formats, infrastructure modifications, and external integrations can complicate recovery.

That’s why deployment standards should be designed around the behaviour of the entire system, not just whether a command exited successfully.

A mature release process should make the safe path the easy path.

Engineers shouldn’t need to reinvent release validation and recovery procedures every time they launch a new service.

Engineering Standards Shouldn’t Depend on Who Wrote the Pipeline

This is where the conversation moves beyond tooling.

Imagine an engineering organization with ten services and five engineers.

Every service has a different deployment workflow. Some use long-lived access keys. Others use OIDC. Some pipelines scan dependencies. Others don’t. A few support automated rollback, while the rest rely on whoever remembers the previous deployment command.

Every engineer has a perfectly reasonable explanation for why their pipeline looks the way it does.

And individually, those decisions might make sense.

But collectively, the organization has created an operational problem.

There is no consistent security baseline, no predictable deployment process, and no shared understanding of what a production-ready pipeline should look like.

Now imagine onboarding another five engineers or growing to fifty services.

The problem doesn’t simply disappear with scale.

It gets more expensive.

If every engineer has to independently decide what a secure deployment pipeline looks like, then the organization hasn’t established an engineering standard.

This is where platform engineering and technical leadership become important.

A good engineering standard should define the minimum expectations that every team must meet while leaving enough flexibility for legitimate differences between workloads.

For example, teams might be required to use temporary credentials, maintain deployment audit trails, enforce production approval policies, and demonstrate a recovery procedure.

But they shouldn’t necessarily be forced to use the same deployment framework, programming language, or runtime platform.

Consistency is valuable where it reduces risk and cognitive load.

Uniformity for its own sake can become another engineering problem.

How I’d Introduce a CI/CD Standard Across an Organization

I wouldn’t begin by announcing that every team must migrate to a new CI/CD platform.

That’s an excellent way to spend six months in meetings while irritating everyone who needs to ship software.

I’d start with an assessment.

What workflows exist today? Which ones can deploy to production? Where are credentials stored? What trust boundaries exist between projects? What happens when a deployment fails?

Then I’d classify the risks.

Not every pipeline requires the same controls. A documentation workflow and a production infrastructure deployment pipeline have very different consequences if compromised.

Once those differences are understood, I’d establish a minimum security and operational baseline.

The next step would be to provide a reference implementation.

Not another forty-page policy document nobody reads.

An actual working pipeline that demonstrates the standards.

Something teams can adopt, adapt, and improve without having to become security specialists first.

I’d roll it out with one or two services, collect feedback, identify where the proposed controls create unnecessary friction, and refine the approach before expanding it.

And I would make exceptions possible, provided they’re documented, risk-assessed, assigned an owner, and reviewed.

Because the purpose of standards isn’t to punish engineering teams for having different requirements.

It’s to establish acceptable risk boundaries and make good engineering practices repeatable.

The best standards reduce the number of decisions engineers have to make repeatedly.

They don’t create a new approval process for every line of YAML.

A Baseline I’d Expect Production Pipelines to Meet

At a minimum, I believe an organization should be able to demonstrate the following:

  • Identity: CI/CD uses narrowly scoped, preferably short-lived credentials, with appropriately restricted trust policies.

  • Isolation: Untrusted build and test jobs are separated from privileged deployment environments.

  • Supply-chain integrity: External actions and dependencies are governed, important versions are pinned, and released artifacts can be traced to their sources.

  • Deployment control: Production deployment requires an authorized workflow with clear rules for approvals and environment access.

  • Auditability: Teams can identify what changed, who or what initiated the deployment, which artifact was released, and when.

  • Recovery: There is a documented and tested approach to failed releases, including changes that cannot be safely rolled back automatically.

  • Ownership: Every production pipeline has an accountable team responsible for maintaining its security and reliability.

  • Operational visibility: Failures, suspicious behaviour, and changes to sensitive workflows can be detected and investigated.

This isn’t an exhaustive security framework.

It’s a starting point.

The controls can evolve as the organization grows, its threat model changes, and its systems become more critical.

But these fundamentals shouldn’t be optional simply because a deployment pipeline happens to be working.

The Real Goal Is Engineering Confidence

I don’t think engineering maturity should be measured by how many tools an organization has adopted.

You can have Kubernetes, Terraform, Argo CD, GitHub Actions, Vault, Prometheus, and every other tool on the CNCF landscape and still have an unreliable or insecure delivery process.

Technology doesn’t automatically create engineering discipline.

Standards do not guarantee it either.

But well-designed standards make expectations clear, reduce avoidable risks, and create systems that teams can operate consistently.

The goal is not to build the most complicated CI/CD architecture possible.

It’s to make sure engineers can ship software confidently without every deployment creating unnecessary risk for the organization.

And that’s the broader point.

CI/CD isn’t just about automating software delivery anymore.

It’s about controlling one of the most privileged pathways into your production environment.

If we agree that production infrastructure deserves proper ownership, security boundaries, monitoring, change management, and recovery planning, then the systems authorized to modify production deserve the same consideration.

Because you can secure every server, database, and network boundary in your environment.

But if you leave the machinery responsible for deploying into those systems poorly protected, you’ve left an important part of your security model exposed.

Your pipeline isn’t just how software gets to production.

It’s part of what determines whether production can be trusted.

And it’s time we started engineering it like it matters.

React
Read this? Get the next one.

Subscribe to Ocheverse.

More from Ocheverse

Back pages
  1. 01/
    Ocheverse · 8 min · 05·11·26The Rise of AI-Related Cloud Abuse: Are We Securing the Wrong Things?
    8′
  2. 02/
    Ocheverse · 6 min · 17·10·26I think you need to start self hosting
    6′
  3. 03/
    Ocheverse · 2 min · 06·05·26I Lead Engineers in Nigeria. In Big Tech, I’d Probably Be an L3. And That Should Scare Us.
    2′

In the margins

Reader notes