Stop a Deployment
Stop all servers for a specific deployment. This command shuts down all servers in the deployment at once, allowing you to control servers at the deployment level rather than individually.
Stopping a deployment does not delete the servers. The servers can be started again using the start command. If the
server configurations have persistent data, the data will be preserved.
Usage
odin fleet deployments stop [--deployment-id=DEPLOYMENT_ID]
Flags
--deployment-id=<number>: The ID of the deployment to stop. If omitted, the CLI will prompt you to select a deployment from a list interactively.
Examples
Stop all servers in a deployment by ID:
Stop a deployment with confirmation bypass (useful for scripts):
Stop a deployment interactively (will prompt for selection):
Use Cases
Cost Optimization: Stop deployments during off-peak hours to reduce costs:
Maintenance Windows: Quickly stop all servers in a deployment for maintenance:
Global Flags
The following flags can be used with any ODIN CLI command:
-
--api-key=<string>The API key to use for authentication. If omitted, the CLI will use the api-key stored in the configuration file on your system. Use odin login to store the API key for subsequent commands. -
--app-id=<string>The ID of the app to use for the command. If omitted, the CLI will use the currently selected app. Use odin apps select to select an app interactively. -
--format=<string>The output format to use for the command. Supported formats arejson,value,flattenedandtable. If omitted, the CLI will use the default format specified in the configuration file. Learn more about output formatting. -
--forceForces the command to execute without prompting for confirmation. Use with caution. -
--quietSuppresses all informational output except for errors. Useful for scripting and automation.