Skip to main content

Overview

Temporal Server can be installed and configured in multiple ways depending on your environment and requirements. This guide covers installation from pre-built binaries, building from source, and configuring various persistence backends.

Installation Methods

Persistence Configuration

Temporal Server supports multiple database backends for persistence. Choose based on your requirements:

SQLite (Development Only)

Best for local development and testing. Data can be in-memory or file-based.
In-memory SQLite does not persist data between server restarts. All workflows and history will be lost when the server stops.

MySQL

Recommended for production deployments with moderate scale.
1

Start MySQL

2

Install Schema

This command:
  • Creates the temporal and temporal_visibility databases
  • Installs the required schema for both databases
  • Applies all schema migrations
You can customize database names using environment variables:
3

Start the Server

PostgreSQL

Recommended for production deployments, offers excellent performance and reliability.
1

Start PostgreSQL

2

Install Schema

Default credentials:
  • User: temporal
  • Password: temporal
To use custom credentials:
3

Start the Server

Cassandra

Best for large-scale deployments requiring horizontal scalability.
1

Start Cassandra

2

Install Schema

With Elasticsearch for advanced visibility:
Without Elasticsearch:
3

Start the Server

Server Configuration

Temporal Server can be configured using YAML configuration files or command-line flags.

Configuration File

Create a custom configuration file based on the provided templates in the config/ directory:

Configuration Options

Key configuration sections:

Environment-Based Configuration

For legacy configuration style using environment variables:

Command-Line Flags

Common flags:
  • --config-file: Path to configuration file
  • --env: Runtime environment (deprecated, use —config-file)
  • --allow-no-auth: Allow server to run without authorization
  • --service: Specify which services to start (frontend, history, matching, worker)

Running Specific Services

You can run individual Temporal services instead of all services:
Default services: frontend, history, matching, worker

Validation and Troubleshooting

Validate Configuration

Validate Dynamic Configuration

Check Server Health

Common Issues

Verify:
  • Database service is running: docker ps or service status
  • Credentials are correct in configuration file
  • Network connectivity: telnet localhost 3306 (MySQL) or 5432 (PostgreSQL)
  • Schema is installed: Run appropriate install-schema-* command
Check if another Temporal instance is running:
Change ports in configuration file if needed.
For development, use the --allow-no-auth flag:
For production, configure proper authorization in the config file.
Update the schema to the latest version:

Production Deployment Considerations

High Availability

  • Run multiple instances of each service type
  • Use a load balancer for frontend service
  • Configure proper health checks
  • Use persistent storage (not SQLite)

Database

  • Use a production-grade database (PostgreSQL, MySQL, or Cassandra)
  • Configure regular backups
  • Monitor database performance
  • Size appropriately based on workflow volume

Security

  • Configure TLS for all service communication
  • Enable authentication and authorization
  • Use secrets management for credentials
  • Restrict network access using firewalls
  • Never use --allow-no-auth in production

Monitoring

  • Configure Prometheus metrics scraping
  • Set up alerting for critical metrics
  • Use Grafana dashboards for visualization
  • Monitor service health and resource usage

Scaling

Key scaling parameters:
Refer to Temporal’s production deployment guide for detailed recommendations.

Next Steps

Quick Start Guide

Get started quickly with Temporal Server

Architecture Documentation

Learn about Temporal Server architecture

Contributing Guide

Contribute to Temporal Server development

Production Deployment

Deploy Temporal in production