kamihi.cli.commands.run
⚓︎
Kamihi framework project execution.
License
MIT
Functions:
| Name | Description |
|---|---|
host_callback |
Ensure the host value is valid. |
run |
Run a project with the Kamihi framework. |
host_callback
⚓︎
host_callback(value: str | None) -> str | None
Ensure the host value is valid.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
|
str | None
|
The host value. |
required |
Returns:
| Type | Description |
|---|---|
str | None
|
str | None: The validated host value. |
Source code in src/kamihi/cli/commands/run.py
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | |
run
⚓︎
run(
ctx: Context,
log_level: Annotated[
LogLevel | None,
Option(
--log - level,
-l,
help="Set the logging level for console loggers.",
show_default=INFO,
),
] = None,
web_host: Annotated[
str | None,
Option(
...,
--host,
-h,
help="Host of the admin web panel",
callback=host_callback,
show_default=localhost,
),
] = None,
web_port: Annotated[
int | None,
Option(
...,
--port,
-p,
help="Port of the admin web panel",
min=1024,
max=65535,
show_default=4242,
),
] = None,
) -> None
Run a project with the Kamihi framework.
Source code in src/kamihi/cli/commands/run.py
43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 | |