Giter Club home page Giter Club logo

cli's Introduction

Temporal CLI

Go Reference ci

⚠️ Temporal CLI's API is still a subject for changes. ⚠️

The Temporal CLI is a command-line interface for running Temporal Server and interacting with Workflows, Activities, Namespaces, and other parts of Temporal.

Getting Started

Installation

Homebrew

brew install temporal

GitHub Releases

Download and extract the latest release from GitHub releases.

Start Temporal server:

temporal server start-dev

At this point you should have a server running on localhost:7233 and a web interface at http://localhost:8233.

Run individual commands to interact with the local Temporal server.

temporal operator namespace list
temporal workflow list

Configuration

Use the help flag to see all available options:

temporal server start-dev -h

Namespace Registration

Namespaces are pre-registered at startup so they're available to use right away.

By default, the "default" namespace is registered. To customize the pre-registered namespaces, start the server with:

temporal server start-dev --namespace foo --namespace bar

Registering namespaces the old-fashioned way via temporal operator namespace register foo works too!

Persistence Modes

In-memory

By default temporal server start-dev run in an in-memory mode.

File on Disk

To persist the state to a file use --db-filename:

temporal server start-dev --db-filename my_test.db

Temporal UI

By default the Temporal UI is started with Temporal CLI. The UI can be disabled via a runtime flag:

temporal server start-dev --headless

To build without static UI assets, use the headless build tag when running go build.

Dynamic Config

Some advanced uses require Temporal dynamic configuration values which are usually set via a dynamic configuration file inside the Temporal configuration file. Alternatively, dynamic configuration values can be set via --dynamic-config-value KEY=JSON_VALUE.

For example, to disable search attribute cache to make created search attributes available for use right away:

temporal server start-dev --dynamic-config-value system.forceSearchAttributesCacheRefreshOnRead=true

Development

To compile the source run:

go build -o dist/temporal ./cmd/temporal

To run all tests:

go test ./...

Known Issues

  • When consuming Temporal as a library in go mod, you may want to replace grpc-gateway with a fork to address URL escaping issue in UI. See temporalio/temporalite-archived#118

  • When running the executables from the Releases page in macOS you will want to allowlist temporal binary in Security & Privacy settings:

image (1)

cli's People

Contributors

feedmeapples avatar jlegrone avatar dependabot[bot] avatar robholland avatar alexshtin avatar jbreiding avatar yycptt avatar cretz avatar yux0 avatar dnr avatar grantfuhr avatar stevekinney avatar sebneira avatar lorensr avatar meiliang86 avatar wxing1292 avatar yiminc avatar tomcz avatar sushisource avatar bergundy avatar plarsson avatar nagl-temporal avatar plaisted avatar laniehei avatar mightyshazam avatar sevein avatar theverything avatar hferentschik avatar afitz0 avatar feihuang avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.