sealed-secrets commands

11 commands, each with a one-line explanation. Click a command to copy it, or its title for details.

Commands 11 shown

  • kubectl create secret generic mysecret --dry-run=client -n <ns> --from-literal=key=value -o yaml | kubeseal -o yaml > sealed.yaml

    Create and seal a k8s secret in one pipeline

    secrets · config

  • kubeseal --fetch-cert --controller-name=sealed-secrets > pub-cert.pem

    Download the sealing certificate for offline operations

    secrets

  • kubeseal --cert pub-cert.pem -o yaml < secret.yaml > sealed.yaml

    Seal without cluster access using pre-fetched certificate

    secrets

  • kubectl get sealedsecret -A

    Show all SealedSecrets and their sync status

    secrets

  • kubeseal --format=yaml < secret.yaml > sealed-secret.yaml

    Encrypt a Kubernetes Secret YAML into a SealedSecret

    security

  • kubectl create secret generic mysecret --dry-run=client --from-literal=token=abc123 -o yaml | kubeseal --scope cluster-wide -o yaml

    Create and seal a secret in cluster-wide scope

    security

  • kubeseal --fetch-cert --controller-name=sealed-secrets --controller-namespace=kube-system > pub.pem

    Save the sealing certificate for offline encryption

    security

  • kubeseal --cert pub.pem --format yaml < secret.yaml > sealed.yaml

    Encrypt without cluster access using saved cert

    security

  • kubectl logs -n kube-system -l app.kubernetes.io/name=sealed-secrets -f

    Stream controller logs to debug sealing issues

    debug

  • kubectl get sealedsecrets -A

    Show all SealedSecrets across namespaces

  • kubectl get secret mysecret -o yaml | kubeseal --format yaml > sealed-new.yaml

    Fetch decrypted secret and re-encrypt with current key

    security