This guide covers building Temporal Server binaries and related tools from source code.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/temporalio/temporal/llms.txt
Use this file to discover all available pages before exploring further.
Initial Build
For your first build, use the defaultmake command to install all build dependencies and compile the binaries:
- Installs required build tools (protoc plugins, linters, etc.)
- Compiles all proto definitions
- Builds all binaries
- Runs the complete test suite
Build Binaries Only
After the initial setup, you can build binaries without running tests:temporal-server- Main server binarytemporal-cassandra-tool- Cassandra schema management tooltemporal-sql-tool- SQL database schema management tooltemporal-elasticsearch-tool- Elasticsearch schema management tooltdbg- Temporal debugging tool
Build Individual Binaries
You can build specific binaries individually:Temporal Server
CGO_ENABLED=0 by default. To enable CGO:
Temporal Server (Debug Build)
TEMPORAL_DEBUG tag, which extends functional test timeouts for debugging sessions.
Database Tools
Cassandra Tool:Debugging Tool
Cross-Platform Builds
You can build for different platforms by settingGOOS and GOARCH:
Build Tags
Temporal Server uses several build tags:disable_grpc_modules- Excludes gRPC dependencies from cloud.google.com/go/storage, reducing binary size by ~16MBtest_dep- Enables test hooks implementation for testingTEMPORAL_DEBUG- Extends timeouts for debuggingintegration- Includes integration test dependencies
Proto Compilation
If you modify.proto files, regenerate the Go code:
- Lints proto definitions
- Compiles proto files to Go code
- Generates service clients and server interceptors
- Generates search attribute helpers
Code Generation
After modifying files with//go:generate directives, run:
- Mock implementations (using mockgen)
- String methods (using stringer)
- RPC wrappers
Clean Build
To remove all build artifacts and start fresh:- All binary files
- Build tools in
.bin/ - Test output in
.testoutput/ - Go test cache