LabOptions¶
- pydantic model controller.models.v1.lab.LabOptions¶
Options for the lab, specified at creation time.
This model represents the configuration information about a running lab returned by a JSON API query. It shares many attributes in common with the input model,
LabRequestOptions
, but reduces the requested image to a Docker image reference and doesn’t support the complex validation required byLabRequestOptions
.- Parameters:
data (
Any
)
Show JSON schema
{ "title": "LabOptions", "description": "Options for the lab, specified at creation time.\n\nThis model represents the configuration information about a running lab\nreturned by a JSON API query. It shares many attributes in common with the\ninput model, `LabRequestOptions`, but reduces the requested image to a\nDocker image reference and doesn't support the complex validation required\nby `LabRequestOptions`.", "type": "object", "properties": { "size": { "$ref": "#/$defs/LabSize", "description": "Size of image, chosen from sizes specified in the controller configuration", "examples": [ "medium" ], "title": "Image size" }, "enable_debug": { "default": false, "description": "If true, set the ``DEBUG`` environment variable when spawning the lab, which enables additional debug logging", "examples": [ true ], "title": "Enable debugging in spawned Lab", "type": "boolean" }, "reset_user_env": { "default": false, "description": "If true, set the ``RESET_USER_ENV`` environment variable when spawning the lab, which tells the lab to move aside the user environment directories (``.cache``, ``.conda``, ``.jupyter``, ``.local``) and files (``.user_setups``). This can be used to recover from user configuration errors that break lab startup.", "examples": [ true ], "title": "Move aside user environment", "type": "boolean" }, "image": { "description": "Docker reference to image used by the lab", "examples": [ "lighthouse.ceres/library/sketchbook:w_2023_07@sha256:abcd" ], "title": "Lab image", "type": "string" } }, "$defs": { "LabSize": { "description": "Allowable names for pod sizes.\n\nTaken from `d20 creature sizes`_.", "enum": [ "fine", "diminutive", "tiny", "small", "medium", "large", "huge", "gargantuan", "colossal", "custom" ], "title": "LabSize", "type": "string" } }, "required": [ "size", "image" ] }
- Fields:
-
field enable_debug: Annotated[bool, Field(title='Enable debugging in spawned Lab', description='If true, set the
DEBUG
environment variable when spawning the lab, which enables additional debug logging', examples=[True])] = False¶ If true, set the
DEBUG
environment variable when spawning the lab, which enables additional debug logging
- field image: Annotated[str, Field(title='Lab image', description='Docker reference to image used by the lab', examples=['lighthouse.ceres/library/sketchbook:w_2023_07@sha256:abcd'])] [Required]¶
Docker reference to image used by the lab
-
field reset_user_env: Annotated[bool, Field(title='Move aside user environment', description='If true, set the
RESET_USER_ENV
environment variable when spawning the lab, which tells the lab to move aside the user environment directories (.cache
,.conda
,.jupyter
,.local
) and files (.user_setups
). This can be used to recover from user configuration errors that break lab startup.', examples=[True])] = False¶ If true, set the
RESET_USER_ENV
environment variable when spawning the lab, which tells the lab to move aside the user environment directories (.cache
,.conda
,.jupyter
,.local
) and files (.user_setups
). This can be used to recover from user configuration errors that break lab startup.
- field size: Annotated[LabSize, Field(title='Image size', description='Size of image, chosen from sizes specified in the controller configuration', examples=[LabSize.MEDIUM])] [Required]¶
Size of image, chosen from sizes specified in the controller configuration