Skip to main content

Overview

Secrets store the credentials Goldsky needs to connect to your infrastructure: database connection details, message queue credentials, cloud provider keys, and HTTP auth headers. They are stored securely in your Goldsky project and referenced by name from your pipeline configuration, so credentials never appear in your YAML.

Managing secrets

Create and manage secrets with the goldsky secret command:
Run goldsky secret -h for the full list of commands.
Deleting a secret that a running pipeline references causes that pipeline to fail on its next connection. Check for references before deleting.

Secret types and the interactive prompt

Running goldsky secret create with no --value starts an interactive prompt that first asks you to pick a secret type, then collects the fields that type requires (host, credentials, region, etc.) and prints the permissions the credentials need before you paste them in. Every stored secret is tagged with one of these types: Compose secrets are created through the goldsky compose CLI.
Turbo webhook sinks accept an httpauth secret via secret_name, but the header it injects cannot also appear in the sink’s inline headers: field. Pick one or the other. See the Turbo webhook sink for details.

Naming secrets

Secret names can only contain alphanumeric characters, underscores (_), and hyphens (-). Use descriptive uppercase names that encode environment and purpose (PROD_POSTGRES_MAIN, STAGING_CLICKHOUSE) rather than secret1 or postgres, so a goldsky secret list stays legible as your project grows.

Rotating credentials

Update a secret in place to rotate credentials without touching any pipeline YAML:
Running pipelines pick up the new value on their next connection.

Referencing a secret in a pipeline

Reference a secret by name in the secret_name field of a sink or transform:

Secret formats

Each sink or transform type expects its own secret format. For Turbo pipelines, database secrets are created from a connection string; queue and storage secrets are JSON objects; HTTP secrets store a header name and value.

Example: PostgreSQL

Postgres is the most common case. Create the secret and paste a standard connection string when prompted:
See the Postgres sink page for database role setup, provider-specific notes, and the inline JSON alternative.
If you use Goldsky-hosted Postgres, provisioning the database automatically registers a secret in your project. There is no separate goldsky secret create step.

Mirror (legacy) secrets

Mirror pipelines use a different format for database secrets: a JSON object with individual connection fields instead of a connection string. For example, a Mirror Postgres secret looks like:
When migrating a Mirror pipeline to Turbo, recreate database secrets in the Turbo connection-string format; see the migration guide. Formats for Mirror-only sinks are documented on the surviving legacy pages, for example Elasticsearch. Mirror pipelines: the guided goldsky pipeline create <pipeline-name> flow lists your existing secrets and offers to create a new one as part of pipeline creation, so you don’t need to create a secret beforehand.

Troubleshooting