Skip to main content

tare identity edit

Edit fields in a local identity file.

The file is read, the requested field is modified, the checksum is recomputed,
and the file is written back atomically. Both wrapped and unwrapped formats
are accepted; the output is always the wrapped format.

The file path defaults to "identity.json" in the current directory.

Examples:
# Set the OTEL auth header via the standard OTEL env var (value contains '=', use --from-file)
echo 'OTEL_EXPORTER_OTLP_HEADERS=Authorization=Bearer <your-token>' > otel.env
tare identity edit --file my.identity.json local-vars set --from-file otel.env

# Or inline (shell quoting required because value contains '=')
tare identity edit --file my.identity.json local-vars set \
OTEL_EXPORTER_OTLP_HEADERS="Authorization=Bearer <your-token>"

# Set auth header directly on the remote telemetry config (SA-driven path)
tare identity edit --file my.identity.json telemetry-headers set \
Authorization="Bearer <your-token>"

# List what is currently set
tare identity edit --file my.identity.json local-vars list
tare identity edit --file my.identity.json telemetry-headers list

Usage:
tare identity edit [flags]
tare identity edit [command]

Available Commands:
local-vars Manage local telemetry environment variables (dataExports.telemetry.local.vars)
serve-url Manage top-level serveUrl field
telemetry-headers Manage telemetry request headers (dataExports.telemetry.headers)

Flags:
-f, --file string Path to the identity JSON file (default: identity.json)

Global Flags:
-q, --quiet Suppress progress output; only errors and the final summary go to stderr
-v, --verbose Verbose output: plain-mode progress lines plus full per-blob chunk logs to stderr

Use "tare identity edit [command] --help" for more information about a command.