Skip to main content

Overview

The YAML Editor provides a powerful in-browser editing experience for Kubernetes manifests. Built on Monaco Editor (the same editor powering VS Code), it offers syntax highlighting, auto-completion, and real-time validation. YAML Editor

Opening the Editor

Access the YAML editor from several places:
Click “Edit YAML” button on deployment detail page
1

Navigate to Deployment

Go to Deployments → Click deployment name
2

Click Edit YAML

Button in top-right of detail page
3

Editor Opens

Modal displays full YAML manifest

Editor Features

Syntax Highlighting

Syntax Highlighting Colored by token type:
  • Blue: Keys (metadata, spec, containers)
  • Green: String values
  • Orange: Numbers and booleans
  • Gray: Comments
  • Red: Syntax errors

Auto-completion

Auto-completion Intelligent suggestions:
Type partial key name for suggestions:
spec:
  temp|    # Suggests: template, terminationGracePeriodSeconds
Kubernetes resource type suggestions:
kind: D|   # Suggests: Deployment, DaemonSet, etc.
Known value suggestions:
imagePullPolicy: |   # Suggests: Always, IfNotPresent, Never
Common patterns:Type container → Full container template Type probe → Health probe template Type volume → Volume mount template
Trigger:
  • Automatic after typing
  • Manual: Ctrl+Space (Windows/Linux) or Cmd+Space (Mac)

Error Detection

Error Detection Real-time validation:
Red squiggly underlines for YAML syntax issuesExamples:
  • Invalid indentation
  • Missing colons
  • Quote mismatch
  • Invalid characters
spec
  replicas 3    # Error: Missing colons

Code Actions

Right-click for quick actions:
Automatic fixes for common issuesExample:
imagePullPolicy: always    # Lowercase

Quick Fix: Change to "Always"
Code improvements:
  • Extract to ConfigMap
  • Move to Secret
  • Add resource limits
Jump to resource definitions:
  • ConfigMap reference → View ConfigMap
  • Secret reference → View Secret

Keyboard Shortcuts

ActionWindows/LinuxMac
SaveCtrl+SCmd+S
FindCtrl+FCmd+F
ReplaceCtrl+HCmd+H
UndoCtrl+ZCmd+Z
RedoCtrl+YCmd+Shift+Z
Comment LineCtrl+/Cmd+/
Format DocumentShift+Alt+FShift+Option+F
Go to LineCtrl+GCmd+G
Multi-cursorAlt+ClickOption+Click
Select All OccurrencesCtrl+Shift+LCmd+Shift+L

Multi-cursor Editing

Edit multiple locations simultaneously:
1

Add Cursors

  • Alt+Click to add cursor
  • Ctrl+Alt+↑/↓ to add cursor above/below
2

Select Occurrences

  • Ctrl+D to select next occurrence
  • Ctrl+Shift+L to select all occurrences
3

Edit

Type to edit all selected locations at once
Example: Change all nginx:1.20 to nginx:1.21:
  1. Select nginx:1.20
  2. Press Ctrl+Shift+L
  3. Type nginx:1.21

Common Editing Tasks

Update Container Image

Search for image: in YAML
containers:
- name: app
  image: myapp:v1.0.0    # Current version

Add Environment Variable

# Before
containers:
- name: app
  image: myapp:v1.0.0

# After
containers:
- name: app
  image: myapp:v1.0.0
  env:
  - name: LOG_LEVEL
    value: "debug"
  - name: DATABASE_URL
    valueFrom:
      secretKeyRef:
        name: db-credentials
        key: url

Update Resource Limits

# Before
resources:
  limits:
    memory: "512Mi"
    cpu: "500m"
  requests:
    memory: "256Mi"
    cpu: "250m"

# After (increased for better performance)
resources:
  limits:
    memory: "1Gi"
    cpu: "1000m"
  requests:
    memory: "512Mi"
    cpu: "500m"

Add Health Probes

# Before
containers:
- name: app
  image: myapp:v1.0.0
  ports:
  - containerPort: 8080

# After (with probes)
containers:
- name: app
  image: myapp:v1.0.0
  ports:
  - containerPort: 8080
  livenessProbe:
    httpGet:
      path: /healthz
      port: 8080
    initialDelaySeconds: 30
    periodSeconds: 10
  readinessProbe:
    httpGet:
      path: /ready
      port: 8080
    initialDelaySeconds: 5
    periodSeconds: 5

Change Replica Count

# Before
spec:
  replicas: 3

# After (scaled up)
spec:
  replicas: 5
Changing replicas in YAML won’t have immediate effect - the change must be merged and applied to the cluster

File Matching

Orphelix can automatically find the YAML file in your repository: File Matching

AI-Powered Matching

Requires: OpenAI API key configured in settings
1

Analyze Deployment

Extracts:
  • Deployment name
  • Namespace
  • Labels
  • Container images
2

Scan Repository

Reads files in repository:
  • YAML files
  • Kustomize bases
  • Helm values
3

AI Matching

Uses GPT-4o-mini to:
  • Compare deployment spec with files
  • Calculate similarity scores
  • Identify best match
4

Present Results

Shows matched file with confidence score:
✓ Found: k8s/deployments/myapp.yaml (95% confidence)

Pattern-based Matching

Fallback method when AI unavailable: Matches by filename patterns:
  • {deployment-name}.yaml
  • deployment-{name}.yaml
  • {name}-deployment.yaml
  • k8s/{name}.yaml
Example:
Deployment: "api-gateway"
Matches:
  ✓ k8s/api-gateway.yaml
  ✓ deployments/api-gateway.yaml
  ✓ api-gateway-deployment.yaml

Kustomize Support

Detects and handles Kustomize structure: Kustomize Editor
1

Detect Kustomize

Finds kustomization.yaml files
2

Show Tabs

Editor displays multiple tabs:
  • Base: base/deployment.yaml
  • Overlay: overlays/production/deployment.yaml
3

Edit Both

Modify base or overlays as needed
4

Create Multi-file PR

Changes to multiple files in single PR

Creating Pull Requests

After editing, submit changes via GitHub:
1

Review Changes

Editor shows diff of your modificationsYAML Diff
  • Green: Added lines
  • Red: Removed lines
  • Yellow: Modified lines
2

Add Commit Message

Enter descriptive commit message:
Update myapp image to v1.1.0

- Bumps image from v1.0.0 to v1.1.0
- Increases memory limit to 1Gi
- Adds liveness probe on /healthz endpoint
3

Select Branch

Choose branch strategy:
Recommended for productionBranch name: update-myapp-v1.1.0Creates new branch → Opens PR
4

Create PR

Click “Create Pull Request”Orphelix:
  1. Creates branch (if selected)
  2. Commits changes
  3. Opens PR on GitHub
  4. Returns PR URL
5

Review on GitHub

Click PR URL to view on GitHub:
  • Review changes
  • Request reviews from team
  • Run CI/CD checks
  • Merge when ready

PR Template

Orphelix auto-generates PR description:
## Changes

Updated deployment: `myapp`

### Modified Files
- `k8s/deployments/myapp.yaml`

### Changes Made
- Updated container image from `myapp:v1.0.0` to `myapp:v1.1.0`
- Increased memory limit from `512Mi` to `1Gi`
- Added liveness probe on `/healthz` endpoint

### Testing
- [ ] Deploy to staging
- [ ] Verify application starts successfully
- [ ] Test liveness probe endpoint
- [ ] Monitor memory usage

---
🤖 Generated with [Orphelix](https://github.com/corapoid/orphelix)

Best Practices

One logical change per PR:
  • ✅ Update image tag
  • ✅ Add health probe
  • ❌ Update image + change replicas + add probes (too much!)
Clear, specific commit messages:✅ Good:
Update nginx image to 1.21.6 for CVE fix
❌ Bad:
Update image
Always review changes:
  • Check diff for unintended modifications
  • Verify indentation is correct
  • Ensure no secrets are exposed
  • Test in staging first
Configure GitHub branch protection:
  • Require pull request reviews
  • Require status checks
  • Prevent force push to main

Troubleshooting

File Not Found

Symptom: “Cannot find YAML file in repository” Solutions:
  1. Manual File Selection
    • Click “Browse Files” button
    • Navigate to correct file
    • Select manually
  2. Check Repository
    • Verify correct repository selected
    • Confirm file exists in repo
    • Check branch (main vs master)
  3. Update File Matching Settings
    • Add custom file patterns in settings
    • Configure OpenAI API key for AI matching

Permission Denied

Symptom: “Failed to create PR: permission denied” Check:
  1. GitHub App Permissions
    • Contents: Read & Write
    • Pull Requests: Read & Write
  2. Repository Access
    • Orphelix app installed on repository?
    • Repository not archived/disabled?
  3. Branch Protection
    • Can create branches?
    • PR allowed from fork?

Merge Conflicts

Symptom: PR shows merge conflicts Resolution:
1

Fetch Latest

Pull latest changes from main
2

Resolve Conflicts

Open GitHub, resolve conflicts in UI
3

Alternative: Start Fresh

Close PR, fetch latest, make changes again

Next Steps

Pull Requests

Learn about PR management

GitHub Setup

Configure GitHub App

Deployments

Back to deployments

Repository Browser

Browse repository files