BuildContext Class

Docker build context for Environment.

Inheritance
builtins.object
BuildContext

Constructor

BuildContext(*, dockerfile_path: str | None = None, path: str | PathLike | None = None)

Parameters

Name Description
path
Required

The local or remote path to the the docker build context directory.

dockerfile_path
Required
str

The path to the dockerfile relative to root of docker build context directory.

Keyword-Only Parameters

Name Description
dockerfile_path
Required
path
Required

Examples

Create a Build Context object.


   from azure.ai.ml.entities._assets.environment import BuildContext

   build_context = BuildContext(dockerfile_path="docker-file-path", path="docker-build-context-path")