Server CLI Commands

A module for CLI to manage the server.

This module defines a custom Typer group (server_cli_group) that wraps the base fastapi dev and fastapi run commands from fastapi-cli.

The main purpose of this wrapper is to provide a consistent and explicit DEFAULT_ENTRYPOINT for the application, minimizing boilerplate configuration for the developer.

This group is intended to be mounted onto the main application CLI.

                                                                                
 Usage: app server [OPTIONS] COMMAND [ARGS]...                                  
                                                                                
 🚀 Commands for running the application server (dev, run).                     
                                                                                
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --install-completion          Install completion for the current shell.      │
│ --show-completion             Show completion for the current shell, to copy │
│                               it or customize the installation.              │
│ --help                        Show this message and exit.                    │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ───────────────────────────────────────────────────────────────────╮
│ dev  Run a FastAPI app in development mode.                                  │
│ run  Run a FastAPI app in production mode.                                   │
╰──────────────────────────────────────────────────────────────────────────────╯