create-environment
/create-environment
Generate Harness Environment YAML for deployment targets and create via MCP. Supports PreProduction and Production types with environment variables, manifest overrides, and multi-environment setup (dev, staging, prod). Use when asked to create an environment, set up staging, configure production, define deployment targets, or manage environment overrides. Trigger phrases: create environment, deployment environment, setup dev, setup staging, setup production, environment variables, environment overrides.
- Author
- harness ↗
- Repository
- harness-skills ↗
- Licence
- Apache-2.0
- Last repository change
- 23.10.2026
Assessment and security
- Files in this package
- 1
- Scripts
- 0
- HTML comments
- 0
- URLs in SKILL.md
- 0
No signals detected. Repository changed on 23.10.2026, without references to retired models or APIs.
Apache-2.0, otwarta: można używać i zmieniać, z zachowaniem licencji i informacji o zmianach.
What it does and when to use it
Generate Harness Environment YAML for deployment targets and create via MCP. Supports PreProduction and Production types with environment variables, manifest overrides, and multi-environment setup (dev, staging, prod). Use when asked to create an environment, set up staging, configure production, define deployment targets, or manage environment overrides. Trigger phrases: create environment, deployment environment, setup dev, setup staging, setup production, environment variables, environment overrides.
Original author description
Generate Harness Environment YAML for deployment targets and create via MCP. Supports PreProduction and Production types with environment variables, manifest overrides, and multi-environment setup (dev, staging, prod). Use when asked to create an environment, set up staging, configure production, define deployment targets, or manage environment overrides. Trigger phrases: create environment, deployment environment, setup dev, setup staging, setup production, environment variables, environment overrides.
How it works
- Instructions
- Environment Structure
- Environment Types
- Multi-Environment Setup
- Creating via MCP
- Examples
- Performance Notes
- Troubleshooting
SKILL.md preview
---
name: create-environment
description: >-
Generate Harness Environment YAML for deployment targets and create via MCP. Supports PreProduction and
Production types with environment variables, manifest overrides, and multi-environment setup (dev,
staging, prod). Use when asked to create an environment, set up staging, configure production, define
deployment targets, or manage environment overrides. Trigger phrases: create environment, deployment
environment, setup dev, setup staging, setup production, environment variables, environment overrides.
metadata:
author: Harness
version: 2.0.0
mcp-server: harness-mcp-v2
summary: Create environments (PreProduction, Production) with overrides
license: Apache-2.0
compatibility: Requires Harness MCP v2 server (harness-mcp-v2)
---
# Create Environment
Generate Harness Environment YAML and push to Harness via MCP.
## Instructions
1. **Determine environment type** - `PreProduction` for dev/staging/QA, `Production` for live environments
2. **Define variables and overrides** - Environment-specific config values and manifest overrides
3. **Generate YAML** using the structure below
4. **Create via MCP** using `harness_create` with resource_type `environment`
## Environment Structure
```yaml
environment:
name: Staging
identifier: staging
orgIdentifier: default
projectIdentifier: my_project
type: PreProduction # PreProduction or Production
tags:
tier: staging
variables:
- name: domain
type: String
value: staging.myapp.com
- name: replicas
type: Number
value: "2"
- name: db_password
type: Secret
value: <+secrets.getValue("staging_db_password")>
overrides:
manifests:
- manifest:
identifier: values_override
type: Values
spec:
store:
type: Github
spec:
connectorRef: github
repoName: config
branch: main
paths: [values-staging.yaml]
```
## Environment Types
- `PreProduction` - Dev, QA, staging, integration environments
- `Production` - Live production environments (enables additional safeguards)
## Multi-Environment Setup
Create dev, staging, and prod:
```yaml
# Dev
environment:
name: Development
identifier: dev
type: PreProduction
variables:
- name: domain
type: String
value: dev.myapp.com
# Staging
environment:
name: Staging
identifier: staging
type: PreProduction
variables:
- name: domain
type: String
value: staging.myapp.com
# Production
environment:
name: Production
identifier: prod
type: Production
variables:
- name: domain
type: String
value: myapp.com
```
## Creating via MCP
```
Call MCP tool: harness_create
Parameters:
resource_type: "environment"
org_id: "<organization>"
project_id: "<project>"
body: <environment YAML>
```
List environments:
```
Call MCP tool: harness_list
Parameters:
resource_type: "environment"
org_id: "<organization>"
project_id: "<project>"
```
## Examples
- "Create dev, staging, and prod environments" - Generate 3 environments with appropriate types
- "Set up a production environment with overrides" - Production type with manifest overrides
## Performance Notes
- When creating multiple environments (dev/staging/prod), ensure variable values are distinct per environment.
- Verify that manifest override paths exist in the referenced repository before creating.
- Use Production type only for live environments — it enables additional safeguards like deployment freezes.
## Troubleshooting
- `DUPLICATE_IDENTIFIER` - Environment exists; use `harness_update`
- Production type enables deployment freeze and approval guardrails
Versions
The database has no other skills named create-environment.
Database snapshot: 13.11.2026 · package version beba66c57074 (SHA-256 digest of the entire package)
Downloads in the last 30 days: 0 · ranking
Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.
Similar skills
- 100langchain-multi-env-setup
Configure LangChain multi-environment setup for dev/staging/prod. Use when managing multiple environments, configuring environment-specific settings, or implementing environment promotion workflows. Trigger with phrases like "langchain environments", "langchain staging",… - 100linear-multi-env-setup
Configure Linear across development, staging, and production environments. Use when setting up multi-environment deployments, managing per-environment API keys, or implementing environment-specific Linear configurations. Trigger with phrases like "linear environments", "linear… - 100arn-infra-env
This skill should be used when the user says "manage environments", "arn infra env", "infra env", "environment setup", "configure environments", "set up staging", "set up production", "environment management", "create environment", "environment promotion", "promote to staging",… - 100clerk-multi-env-setup
Configure Clerk for multiple environments (dev, staging, production). Use when setting up environment-specific configurations, managing multiple Clerk instances, or implementing environment promotion. Trigger with phrases like "clerk environments", "clerk staging", "clerk dev… - 100environment-setup
Configure and manage development, staging, and production environments. Use when setting up environment variables, managing configurations, or separating environments. Handles .env files, config management, and environment-specific settings. - 100customerio-multi-env-setup
Configure Customer.io multi-environment setup with workspace isolation. Use when setting up dev/staging/prod workspaces, environment-aware clients, or Kubernetes config overlays. Trigger: "customer.io environments", "customer.io staging", "customer.io dev prod", "customer.io workspace isolation".