Skip to content

Latest commit

 

History

History
111 lines (72 loc) · 3.38 KB

README.md

File metadata and controls

111 lines (72 loc) · 3.38 KB

💻 Command Line Interface (CLI)

Effectively manage your workflows using the versatile Command Line Interface (CLI) designed for a variety of tasks. This CLI is provided as a base executable that includes built-in extensions.

Configuration

Settings can be modified using the .uniflow.toml file or system environment variables. The key configuration options are:

TOML Key Environment Variable Key Example
database.url DATABASE_URL mem:// or mongodb://
database.name DATABASE_NAME -
collection.charts COLLECTION_CHARTS charts
collection.specs COLLECTION_SPECS nodes
collection.secrets COLLECTION_SECRETS secrets

If you are using MongoDB, enable Change Streams to track resource changes in real time. This requires setting up a replica set.

Using Uniflow

uniflow is primarily used to start and manage the runtime environment.

Start Command

The start command executes all node specifications in the specified namespace. If no namespace is provided, the default namespace (default) is used.

./dist/uniflow start --namespace default

If the namespace is empty, you can provide an initial node specification using the --from-specs flag:

./dist/uniflow start --namespace default --from-specs examples/specs.yaml

You can specify an initial secrets file with the --from-secrets flag:

./dist/uniflow start --namespace default --from-secrets examples/secrets.yaml

Charts can be initialized using the --from-charts flag:

./dist/uniflow start --namespace default --from-charts examples/charts.yaml

Using Uniflowctl

uniflowctl is a command used to manage resources within a namespace.

Apply Command

The apply command applies the contents of a specified file to the namespace. If no namespace is specified, the default namespace is used.

./dist/uniflowctl apply nodes --namespace default --filename examples/specs.yaml

To apply secrets:

./dist/uniflowctl apply secrets --namespace default --filename examples/secrets.yaml

To apply charts:

./dist/uniflowctl apply charts --namespace default --filename examples/charts.yaml

Delete Command

The delete command removes all resources defined in the specified file. If no namespace is specified, the default namespace is used.

./dist/uniflowctl delete nodes --namespace default --filename examples/specs.yaml

To delete secrets:

./dist/uniflowctl delete secrets --namespace default --filename examples/secrets.yaml

To delete charts:

./dist/uniflowctl delete charts --namespace default --filename examples/charts.yaml

Get Command

The get command retrieves all resources in the specified namespace. If no namespace is specified, the default namespace is used.

./dist/uniflowctl get nodes --namespace default

To retrieve secrets:

./dist/uniflowctl get secrets --namespace default

To retrieve charts:

./dist/uniflowctl get charts --namespace default