prefect deployment
prefect deployment [OPTIONS] COMMAND [ARGS]...
prefect deployment inspect
prefect deployment inspect [OPTIONS] NAME
View details about a deployment.
Example:
$ prefect deployment inspect “hello-world/my-deployment”
$ prefect deployment inspect “hello-world/my-deployment” —output json
{
‘id’: ‘610df9c3-0fb4-4856-b330-67f588d20201’,
‘created’: ‘2022-08-01T18:36:25.192102+00:00’,
‘updated’: ‘2022-08-01T18:36:25.188166+00:00’,
‘name’: ‘my-deployment’,
‘description’: None,
‘flow_id’: ‘b57b0aa2-ef3a-479e-be49-381fb0483b4e’,
‘schedules’: None,
‘parameters’: {‘name’: ‘Marvin’},
‘tags’: [‘test’],
‘parameter_openapi_schema’: {
‘title’: ‘Parameters’,
‘type’: ‘object’,
‘properties’: {
‘name’: {
‘title’: ‘name’,
‘type’: ‘string’
}
},
‘required’: [‘name’]
},
‘storage_document_id’: ‘63ef008f-1e5d-4e07-a0d4-4535731adb32’,
‘infrastructure_document_id’: ‘6702c598-7094-42c8-9785-338d2ec3a028’,
‘infrastructure’: {
‘type’: ‘process’,
‘env’: {},
‘labels’: {},
‘name’: None,
‘command’: [‘python’, ‘-m’, ‘prefect.engine’],
‘stream_output’: True
}
}
Specify an output format. Currently supports: json
prefect deployment ls
prefect deployment ls [OPTIONS]
View all deployments or deployments for specific flows.
prefect deployment run
prefect deployment run [OPTIONS] [NAME]
Create a flow run for the given flow and deployment. The flow run will be scheduled to run immediately unless `—start-in` or `—start-at` is specified.
The flow run will not execute until a worker starts.
To watch the flow run until it reaches a terminal state, use the `—watch` flag.
A deployed flow’s name: <FLOW_NAME>/<DEPLOYMENT_NAME>
A deployment id to search for if no name is given
A key, value pair (key=value) specifying a flow run job variable. The value will be interpreted as JSON. May be passed multiple times to specify multiple job variable values.
A key, value pair (key=value) specifying a flow parameter. The value will be interpreted as JSON. May be passed multiple times to specify multiple parameter values.
A mapping of parameters to values. To use a stdin, pass ’-’. Any parameters passed with `—param` will take precedence over these values.
A human-readable string specifying a time interval to wait before starting the flow run. E.g. ‘in 5 minutes’, ‘in 1 hour’, ‘in 2 days’.
A human-readable string specifying a time to start the flow run. E.g. ‘at 5:30pm’, ‘at 2022-08-01 17:30’, ‘at 2022-08-01 17:30:00’.
Tag(s) to be applied to flow run.
Whether to poll the flow run until a terminal state is reached.
How often to poll the flow run for state changes (in seconds).
prefect deployment delete
prefect deployment delete [OPTIONS] [NAME]
Delete a deployment.
Examples:
$ prefect deployment delete test_flow/test_deployment
$ prefect deployment delete —id dfd3e220-a130-4149-9af6-8d487e02fea6
A deployed flow’s name: <FLOW_NAME>/<DEPLOYMENT_NAME>
A deployment id to search for if no name is given
prefect deployment schedule
prefect deployment schedule [OPTIONS] COMMAND [ARGS]...
Manage deployment schedules.
prefect deployment schedule create
prefect deployment schedule create [OPTIONS] NAME
Create a schedule for a given deployment.
An interval to schedule on, specified in seconds
The anchor date for an interval schedule
Deployment schedule rrule string
Deployment schedule cron string
Control how croniter handles `day` and `day_of_week` entries
Deployment schedule timezone string e.g. ‘America/New_York’
Whether the schedule is active. Defaults to True.
Replace the deployment’s current schedule(s) with this new schedule.
Accept the confirmation prompt without prompting
prefect deployment schedule delete
prefect deployment schedule delete [OPTIONS] DEPLOYMENT_NAME SCHEDULE_ID
Delete a deployment schedule.
Accept the confirmation prompt without prompting
prefect deployment schedule pause
prefect deployment schedule pause [OPTIONS] DEPLOYMENT_NAME SCHEDULE_ID
Pause a deployment schedule.
prefect deployment schedule resume
prefect deployment schedule resume [OPTIONS] DEPLOYMENT_NAME SCHEDULE_ID
Resume a deployment schedule.
prefect deployment schedule ls
prefect deployment schedule ls [OPTIONS] DEPLOYMENT_NAME
View all schedules for a deployment.
prefect deployment schedule clear
prefect deployment schedule clear [OPTIONS] DEPLOYMENT_NAME
Clear all schedules for a deployment.
Accept the confirmation prompt without prompting