ankra-sops-secrets

Encrypt Kubernetes Secrets in GitOps repos using SOPS with AGE.

26|2|Updated Jul 11, 2025
One-click install
npx skills add https://github.com/ankraio/ankra-cli --skill ankra-sops-secrets
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ankra-sops-secrets
Source: https://github.com/ankraio/ankra-cli/tree/main/internal/skills/embedded/skills/ankra-sops-secrets
Command: npx skills add https://github.com/ankraio/ankra-cli --skill ankra-sops-secrets

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Encrypt Kubernetes Secrets and sensitive values stored in a GitOps repository using SOPS with AGE, and track them with encrypted_paths so Ankra decrypts at deploy time. Use when you need to store secrets in Git, mention SOPS, AGE, encrypted_paths, or the ankra cluster encrypt/decrypt/sops-config commands.

Core Features & Use Cases

  • Encrypt secrets at rest using SOPS with AGE keys to ensure plaintext never lands in Git.
  • Define encrypted_paths on manifests and addons to selectively de-encrypt at deploy time.
  • Integrate with ankra cluster encrypt/decrypt to support file-mode and cluster-mode workflows across environments.

Quick Start

Encrypt a secret in a Kubernetes manifest by running ankra cluster encrypt and ensure the encrypted_paths include the secret key.

Frequently Asked Questions about ankra-sops-secrets

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I encrypt Kubernetes Secrets for GitOps using SOPS and AGE?

Encrypt Kubernetes Secrets using SOPS with AGE keys to prevent plaintext leakage in GitOps repositories. Define encrypted_paths metadata on manifests to ensure Ankra selectively decrypts sensitive values at deploy time.

How does SOPS prevent plaintext secrets from leaking in GitOps repositories?

SOPS encrypts Kubernetes Secrets at rest using AGE keys, ensuring plaintext never lands in Git. The encrypted_paths metadata marks which YAML keys are encrypted, enabling selective decryption at deploy time.

Do I need encrypted_paths metadata to decrypt Kubernetes Secrets at deploy time?

Yes, encrypted_paths metadata is required to specify which YAML keys are encrypted. Ankra uses this metadata to selectively decrypt sensitive values in manifests and addons across clusters at deploy time.

Can I use SOPS with AGE to encrypt secrets across multiple Kubernetes clusters?

Yes, SOPS with AGE supports file-mode and cluster-mode workflows across environments. Integrate with ankra cluster encrypt/decrypt commands to manage secrets for manifests and addons across multiple clusters.

What is the best way to manage Kubernetes Secrets in a GitOps workflow?

Using SOPS with AGE is an effective approach for GitOps secret management. It encrypts sensitive values before commit and tracks them with encrypted_paths so Ankra decrypts them at deploy time.

Why does SOPS require AGE keys for encrypting Kubernetes Secrets in GitOps?

SOPS uses AGE keys to encrypt Kubernetes Secrets at rest, preventing plaintext leakage in GitOps repositories. This ensures sensitive values remain encrypted until Ankra decrypts them at deploy time.