Skip to main content

IDP Workflow Patterns and Examples

Last updated on

Workflows turn Harness pipelines into self-service actions in the Internal Developer Portal. This page outlines repeatable patterns many platform teams automate (onboarding, infrastructure, feature flags, secrets, and Kubernetes operations), with example inputs, typical pipeline steps, and links to the Harness docs that define each step.

For rollout and adoption context, see the IDP adoption playbook. For hands-on setup, see the Self-Service Workflows overview, configure the Harness pipeline backend, the Workflow YAML reference, and Managing workflows.

Common workflow use cases

Use workflows for recurring tasks that need consistency and auditability, such as onboarding or offboarding, new services, infrastructure requests, and routine operational changes.

Below are seven examples this page expands on:

  1. Service onboarding
  2. Infrastructure provisioning
  3. Toggling feature flags
  4. Rotating secrets
  5. Rolling back deployments
  6. Scaling for traffic
  7. Restarting services

Service onboarding

Service onboarding is one of the highest-value IDP use cases: scaffolding repositories, standard Dockerfiles, tests, configs, and layout before application code lands. A follow-on Harness pipeline can standardize build, test, scan, and deploy.

A common pattern is a pipeline that creates a pipeline: scaffold the repo, register the service in the IDP catalog, create a CI/CD pipeline (often via the Harness Terraform provider through a Create Resource step), and notify the team on Slack.

Service onboarding flow (scaffold, catalog, pipeline, notify)

Harness pipeline

Harness pipeline screenshot for service onboarding

Pipeline steps

StepHarness step (type)Description
CookiecutterCookieCutterScaffold repo code from a template
CreateRepoCreateRepoCreate the repository in your Git provider
CreateCatalogCreateCatalogCreate catalog-info.yaml for catalog registration
DirectPushDirectPushPush generated code to Git
RegisterCatalogRegisterCatalogRegister the entity in Harness IDP
Create pipeline for serviceCreateResourceRun an OpenTofu module (Harness Terraform provider) to create a CI/CD pipeline or other Harness entities; often from a template
Notify TeamSlackNotifyPost a Slack message (for example, using outputs from prior IDP steps)

Example workflow form fields

Project NameName of project
Repository typePublic or Private
Repository descriptionDescription
Email for notificationEmail for Slack notification
Template urlCookiecutter template url
ownerRepo owner (Harness User/Group)
stackTech Stack

Example workflow (IDP)

Service onboarding - workflow form in IDP

Related documentation: Onboard a GitHub repository with a workflow, Service onboarding with the IDP stage, Create a Service from a workflow, and Set up the Harness IDP pipeline.

Infrastructure provisioning

Infrastructure provisioning is a natural fit for IDP: it replaces ad hoc tickets and manual checks with a governed pipeline while preserving approvals and audit history.

A typical flow creates a change ticket, runs Terraform through IaCM, gates on approval, evaluates policy on the plan output, and updates the ticket. You might add scheduled runs to review or tear down resources.

Infrastructure provisioning flow (change management, IaCM, and governance)

Harness pipeline

Harness pipeline screenshot for infrastructure provisioning

Pipeline steps

StageDiagramHarness step (type)Description
Change ManagementIcon for change management / Jira ticket stepJiraCreateCreate a Jira issue for traceability (see tutorial YAML)
Infra as Code Provisioning (plan)IaCM plan phase - init, lint, tfsec, drift, and planIACM stage: IACMTerraformPlugin, optional lint Plugin (for example tfsec)Init, lint, security scan, drift detection, and Terraform plan in the IaCM workspace as in the provision tutorial
Infra as Code Provisioning (apply)IaCM apply phase - export plan, approval, and applyRun (export plan), IACMApproval, IACMTerraformPlugin (apply)Export the plan for downstream checks, gate on approval, then apply infrastructure changes as in the provision tutorial
Governance ManagementIcon for governance / OPA on planPolicy, JiraUpdateEvaluate OPA on the exported plan payload; update Jira with results

Example workflow form fields

OwnerHarness User/Group
iacm_workspaceIaCM Workspace
Jira ProjectJira Project
Jira Issue SummaryJira Issue Summary for infrastructure
Cloud ProviderGCP, AWS, etc
Instance TypeEnum for supported instances
AMIAmazon Machine Image
SubnetDeployed Subnet
VPCDeployed VPC
Instance CountInstance count

Example workflow (IDP)

Infrastructure provisioning - workflow form page 1 (request context)

Infrastructure provisioning - workflow form page 2 (infrastructure details)

Related documentation: Provision infrastructure using IDP and IaCM, Policy as code in IDP, and the Jira plugin.

Examples

These are smaller, frequent operations that benefit from the same guardrails: workflow RBAC, approvals, and a single place to see execution history.

Flipping a feature flag

Changing a feature flag or its targeting is simple in the UI, but you may still want an auditable path: OPA on save, workflow RBAC, and pipeline checks so only allowed users change production targeting.

Harness Feature Management & Experimentation (FME) provides first-class pipeline steps for flag operations; combine them with a Policy step when you need to validate workflow inputs. See FME and Harness pipelines.

Feature flag governance and targeting flow

Harness pipeline

Harness pipeline screenshot for feature flag governance and targeting

Pipeline steps

StepHarness step (type)Description
Flag change governancePolicyValidate workflow parameters (custom payload) against policy
Enable flag for target userFmeFlagAddRemoveIndividualTargetsConditionally add an individual target
Disable flag for target userFmeFlagAddRemoveIndividualTargetsConditionally remove an individual target

Example workflow inputs

InputDescription
Flag nameFeature flag identifier in your project
Target user keyTarget id (for example, user or account key)
actionEnum for enable/disable
environmentFME environment for the change

Example workflow (IDP)

Feature flag change - workflow form in IDP

Related documentation: FME overview, Feature flags and pipelines, Targeting, Policy as Code for FME, and FME policies.

Rotating a token

Token rotation fits the same pattern: an approval, an Http call to your identity or API provider, then another HTTP call (or script) to store the new value in Harness secrets.

Using Harness HTTP steps you can mirror the feature-flag workflow: wrap sensitive API actions with governance and controls.

Secret rotation flow (approval and HTTP steps)

Harness pipeline

Harness pipeline screenshot for secret rotation

Pipeline steps

StepHarness step (type)Description
Approve RotationHarnessApprovalRequire human approval before rotation
Rotate TokenHttpCall the provider API to rotate or issue a new token
Update secretTextHttpCall the Harness API (or your process) to update the stored secret value

Workflow inputs (account- or org-scoped secrets example)

InputDescription
Token identifierLogical name or id for the token being rotated
Org for rotation APIHarness org id (or scope) used in the rotation API call
Service account identifierService account or principal the token belongs to
API Key identifierAPI key or client id used to authenticate the rotation request
Secret identifierHarness secret identifier to update after rotation
Secret scoped orgOrg id when the secret is org-scoped
Secret display nameHuman-readable name shown in the UI

Example workflow (IDP)

Token rotation - workflow form in IDP

Related documentation: Using a short-lived secret to trigger a workflow, HTTP step, and Add and use text secrets.

Rolling back a deployment

When deployments are frequent, teams need a controlled rollback path. IDP can expose rollback to the right people with approvals and full execution history instead of ad hoc kubectl or UI-only changes.

Deployment rollback flow with approval

Harness pipeline

Harness pipeline screenshot for deployment rollback
Pipeline steps

StepHarness step (type)Description
Approve rollbackHarnessApprovalApprove rollback of the selected workload
K8s rolling rollbackK8sRollingRollbackRoll back the Kubernetes workload to the last successful release

Example workflow inputs

Service IdentifierService
Environment IdentifierDeployment Environment
InfradefInfrastructure for environment

Example workflow (IDP)

Deployment rollback - workflow form in IDP

Related documentation: Rollback deployments and Kubernetes rollback.

Scaling for traffic

Scaling workloads is another good workflow candidate: one standard pipeline, RBAC on who can run it, and traceability for every change.

Kubernetes scale flow with approval

Harness pipeline

Harness pipeline screenshot for Kubernetes scale
Pipeline steps

StepHarness step (type)Description
Approve scaleHarnessApprovalApprove changing replica count
K8s ScaleK8sScaleScale the workload in or out

Example workflow inputs

Service IdentifierPipeline service identifier
Environment IdentifierPipeline environment identifier
Infrastructure DefinitionPipeline infrastructure definition
Namespace[namespace/]Kind/Name
Target ReplicasDesired replica count

Example workflow (IDP)

Scale workload - workflow form in IDP

Related documentation: Scale Kubernetes replicas.

Restarting a service

Restarting is similar to scaling: approval plus a Kubernetes step that refreshes pods without a full redeploy.

Rolling restart flow with approval

Harness pipeline

Harness pipeline screenshot for rolling restart
Pipeline steps

StepHarness step (type)Description
Approve restartHarnessApprovalApprove the restart
Rolling restartK8sRollout (command: restart) or K8sPatchRolling restart or patch-based refresh of the workload

Example workflow inputs

Service IdentifierPipeline service identifier
Environment IdentifierPipeline environment identifier
Infrastructure DefinitionPipeline infrastructure definition
Namespace[namespace/]Kind/Name

Example workflow (IDP)

Restart service - workflow form in IDP

Related documentation: Kubernetes Rollout restart and Kubernetes Patch step.