Generate Server Secret Command

The generate-server-secret command creates a new secret key for server authentication.

Usage

ocuroot generate-server-secret [flags]

Description

The generate-server-secret command creates a new secret key that is used by the Ocuroot server for:

  • Securing server communications
  • Encrypting sensitive data
  • Authenticating server instances

Flags

  • --length: Specify the length of the generated secret
  • --output: Save the secret to a file

Examples

# Generate a new server secret
ocuroot generate-server-secret

# Generate a secret with specific length
ocuroot generate-server-secret --length 64

# Save secret to file
ocuroot generate-server-secret --output server-secret.key

Security Considerations

  • Keep server secrets secure and private
  • Use secure storage solutions for production secrets
  • Rotate secrets periodically
  • Never expose secrets in logs or error messages
  • Avoid committing secrets to version control
  • server: Start the Ocuroot server