This document describes the specification of cottage.toml and *.cott.toml files used by cottage.
Project Configuration - cottage.toml
Root Fields
UpstreamConfig
PullPushConfig
Secret Metadata - .cott.toml
Root Fields
ChecksumMetadata
PreviewMetadata
SecretMetadata
UpstreamMetadata
The cottage.toml file is located at the project root and defines global and upstream settings.
Field Type Description
upstreamMap<String, UpstreamConfig > Optional. Defines upstream configurations for pulling/pushing secrets.
These settings can be defined at the top level of an upstream or within its pull/push sections.
Field Type Description
cwdBoolean Optional. If true, run the script in the directory of the secret.
envfilePath Optional. Path to an encrypted file to use as environment variables for the script.
varsMap<String, String> Optional. Environment variables to pass to the script. If any variable value is a path to a decrypted secret that has a corresponding encrypted counterpart, it is automatically added to the requires list.
requiresArray Optional. List of secret paths to be decrypted before running push/pull operations (and securely cleaned up afterwards).
shellString Optional. The shell to use for running scripts (default: sh).
pullPullPushConfig Optional. Specific configuration for the pull operation.
pushPullPushConfig Optional. Specific configuration for the push operation.
pluginString Optional. Path to a plugin executable.
Inherits defaults from UpstreamConfig.
Field Type Description
cwdBoolean Optional.
envfilePath Optional.
varsMap<String, String> Optional.
requiresArray Optional.
shellString Optional.
scriptString Optional. The shell script to execute for the operation.
pluginString Optional. Path to a plugin executable.
Every encrypted file *.cott.age has a corresponding *.cott.toml metadata file.
Field Type Description
checksumChecksumMetadata Auto generated. Integrity checks for the encrypted data and recipients.
previewPreviewMetadata Auto generated for specific file types. Values-redacted preview of the content.
secretSecretMetadata Metadata about the secret itself.
upstreamMap<String, UpstreamMetadata > Optional. Upstream-specific settings for this secret.
Field Type Description
encryptedString BLAKE3 checksum of the encrypted file content (prefixed with blake3:).
recipientsString BLAKE3 checksum of the recipients used to encrypt the file.
Field Type Description
formatString One of: yaml, json, toml, dotenv, ini, hcl.
previewString The value-redacted preview content.
Field Type Description
timestampString Auto generated. Last modified timestamp of the secret.
allowArray Optional. List of glob patterns for allowed recipients.
denyArray Optional. List of glob patterns for denied recipients.
Field Type Description
varsMap<String, String> Optional. Secret-specific environment variables for upstream operations.
pullBoolean Optional. Whether to allow pulling this secret from the upstream.
pushBoolean Optional. Whether to allow pushing this secret to the upstream.