Skip to main content

build_docker_image

Function build_docker_image 

Source
pub fn build_docker_image(image: &str, file_path: &str) -> Result<(), String>
Expand description

Builds a Docker image from a given build context directory.

§Arguments

  • image - A string slice that holds the name of the Docker image to build
  • file_path - A string slice that holds the path to the Dockerfile

§Returns

  • Result<(), String> - A result that indicates if the Docker image was built successfully or an error message