filebackend

package
v1.366.0 Latest Latest
Warning

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

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

Documentation

Overview

Package filebackend contains implementation details shared by file-backed vaults.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsSOPSEncryptedYAML

func IsSOPSEncryptedYAML(data []byte) (bool, error)

IsSOPSEncryptedYAML reports whether a YAML document contains SOPS metadata.

func Marshal

func Marshal(data *files.InstallVault, comments bool) ([]byte, error)

Marshal serializes install vault data for storage.

func Parse

func Parse(data []byte) (*files.InstallVault, error)

Parse unmarshals vault YAML, including SOPS whole-file wrapper output.

func Write

func Write(fileIO util.FileIO, path string, data []byte) error

Write atomically writes vault data to path.

Types

type Options

type Options struct {
	Path         string
	WithComments bool
	FileIO       util.FileIO
}

Options contains configuration shared by file-backed vault implementations.

func WithDefaults

func WithDefaults(opts Options) Options

WithDefaults fills optional file backend dependencies.

Jump to

Keyboard shortcuts

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