prefect worker

prefect worker [OPTIONS] COMMAND [ARGS]...

Start and interact with workers.

prefect worker start

prefect worker start [OPTIONS]

Start a worker process to poll a work pool for flow runs.

-n

The name to give to the started worker. If not provided, a unique name will be generated.

-p

The work pool the started worker should poll.

-q

One or more work queue names for the worker to pull from. If not provided, the worker will pull from all work queues in the work pool.

-t

The type of worker to start. If not provided, the worker type will be inferred from the work pool.

--prefetch-seconds

Number of seconds to look into the future for scheduled flow runs.

--run-once

Only run worker polling once. By default, the worker runs forever.

-l

Maximum number of flow runs to start simultaneously.

--with-healthcheck

Start a healthcheck server for the worker.

--install-policy

Install policy to use workers from Prefect integration packages.

--base-job-template

The path to a JSON file containing the base job template to use. If unspecified, Prefect will use the default base job template for the given worker type. If the work pool already exists, this will be ignored.