Skip to content

Environment Variables

Ashley Davis edited this page Jun 14, 2026 · 4 revisions

This page documents all environment variables recognised by Photosphere.

AWS / S3 Variables

S3 credentials are never stored in a config file. When a database has no linked S3 credential secret in the vault, Photosphere reads AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_REGION, and AWS_ENDPOINT directly from process.env to construct S3 credentials.

Variable Description Example
AWS_ACCESS_KEY_ID S3 access key ID AKIAIOSFODNN7EXAMPLE
AWS_SECRET_ACCESS_KEY S3 secret access key wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
AWS_REGION S3 region (defaults to us-east-1 when unset) us-east-1
AWS_ENDPOINT S3 endpoint URL (for non-AWS S3-compatible services) https://nyc3.digitaloceanspaces.com

Other Variables

Variable Description Default
GOOGLE_API_KEY Google API key for reverse geocoding None
PSI_ENCRYPTION_KEY Encryption key for encrypted storage: a PEM file path or a vault secret name. Used as a fallback when no key is passed via the -k flag and the database has no linked encryption key. None
PHOTOSPHERE_VAULT_TYPE Selects the vault backend: keychain (OS keychain) or plaintext (JSON files on disk) keychain
PHOTOSPHERE_VAULT_DIR Overrides the vault directory path (only used with the plaintext backend) ~/.config/photosphere/vault/
PHOTOSPHERE_CONFIG_DIR Overrides the Photosphere config directory ~/.config/photosphere/
PHOTOSPHERE_LOG_DIR Overrides the directory where log files are written System temp directory
PHOTOSPHERE_NEWS_URL Overrides the URL of the news feed. The desktop app checks it at startup and the CLI checks it before running a command (except news and bug). Accepts http://, https://, and file:// URLs. https://raw.githubusercontent.com/ashleydavis/photosphere/main/news.yaml

Example: plaintext vault for scripting or CI

export PHOTOSPHERE_VAULT_TYPE=plaintext
export PHOTOSPHERE_VAULT_DIR=/path/to/vault

Related Configuration

Clone this wiki locally