orangeqs.juice.orchestration.environment#
Management of the environments of the OrangeQS Juice installation.
Module Contents#
Functions#
Return the mounts required at runtime for a given environment. |
|
Return the build environment settings for a given environment. |
|
Render the files that define an environment to its own environment folder. |
|
Return a list of all environment names defined in the orchestration settings. |
|
Render all environments defined in the orchestration settings. |
API#
- orangeqs.juice.orchestration.environment.runtime_environment_mounts(name: str, settings: orangeqs.juice.orchestration.settings.EnvironmentSettings, env_folder: pathlib.Path) list[str]#
Return the mounts required at runtime for a given environment.
For now this only includes mounts for editable sources.
Parameters#
name (str): The name of the environment.
settings (EnvironmentSettings): The settings for the environment.
env_folder (Path): The folder where environment data is stored.
Returns#
(list[str]): A list of mount paths required for the environment at runtime. The format is docker/podman compatible, meaning that it can be used directly in the
-vor--mountflag
- orangeqs.juice.orchestration.environment.build_settings(name: str, settings: orangeqs.juice.orchestration.settings.EnvironmentSettings, data_folder: orangeqs.juice.orchestration.settings.DataFolderSettings) orangeqs.juice.orchestration.settings.BuildSettings#
Return the build environment settings for a given environment.
- orangeqs.juice.orchestration.environment.render_environment(name: str, settings: orangeqs.juice.orchestration.settings.EnvironmentSettings, env_folder: pathlib.Path) list[pathlib.Path]#
Render the files that define an environment to its own environment folder.
It writes the files to a separate folder for each environment. For a
uvenvironment the files arepyproject.tomlandContainerfile.Parameters#
name (str): The name of the environment.
settings (EnvironmentSettings): The settings for the environment.
env_folder (Path): The folder where environment data is stored for all environments.
Returns#
(list[Path]): A list of paths to the rendered files for the environment.
- orangeqs.juice.orchestration.environment.list_environments(orchestration_settings: orangeqs.juice.orchestration.settings.OrchestrationSettings) dict[str, orangeqs.juice.orchestration.settings.EnvironmentSettings]#
Return a list of all environment names defined in the orchestration settings.
This includes environments for each service and the singleuser environment.
Parameters#
orchestration_settings (OrchestrationSettings): The orchestration settings containing the environments to list.
Returns#
(dict[str, EnvironmentSettings]): A dictionary where the keys are environment names and the values are the corresponding environment settings.
- orangeqs.juice.orchestration.environment.render_environments(orchestration_settings: orangeqs.juice.orchestration.settings.OrchestrationSettings) dict[str, list[pathlib.Path]]#
Render all environments defined in the orchestration settings.
It writes the files to a separate folder for each environment. These files can subsequently be used to build each environment. Consists of one environment per service and the singleuser environment.
Parameters#
orchestration_settings (OrchestrationSettings): The orchestration settings containing the environments to render.
Returns#
(dict[str, list[Path]]): A dictionary where the keys are environment names and the values are lists of paths to the rendered files for each environment.