clustercfg

package
v0.15.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 28, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package clustercfg is used to parse an byte array and returns a ZarfCluster

Index

Constants

View Source
const AnsibleVaultPasswordEnvVar = "ANSIBLE_VAULT_PASSWORD"

AnsibleVaultPasswordEnvVar is a secondary environment variable checked for the Ansible Vault password, used by ansible-vault itself. VaultPasswordEnvVar takes precedence when both are set.

View Source
const VaultPasswordEnvVar = "CARGOSHIP_VAULT_PASSWORD"

VaultPasswordEnvVar is the environment variable checked for the Ansible Vault password when no --vault-password-file flag is given.

Variables

This section is empty.

Functions

func DecryptRegistryAuth added in v0.15.0

func DecryptRegistryAuth(dis *cluster.ZarfCluster, password string) error

DecryptRegistryAuth decrypts any Ansible Vault-encrypted Username, Password, or Token fields on dis.Spec.Config.Registries in place. Fields that don't carry the $ANSIBLE_VAULT header are left untouched.

func EncryptValue added in v0.15.0

func EncryptValue(value, password string) (string, error)

EncryptValue encrypts value with the given Ansible Vault password, producing a string suitable for use as a registry auth field (see DecryptRegistryAuth).

func Parse

func Parse(_ context.Context, b []byte) (cluster.ZarfCluster, error)

Parse parses the yaml passed as a byte slice and applies schema migrations.

func ResolveVaultPassword added in v0.15.0

func ResolveVaultPassword(passwordFile string) (string, error)

ResolveVaultPassword returns the Ansible Vault password to use for decrypting registry credentials. If passwordFile is set, its contents are read and used. Otherwise it falls back to the CARGOSHIP_VAULT_PASSWORD environment variable, then to ANSIBLE_VAULT_PASSWORD. An empty return value with a nil error means no password was configured.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL