MCPcopy Create free account
hub / github.com/Paper2Poster/Paper2Poster / copy

Method copy

camel/runtime/docker_runtime.py:105–120  ·  view source on GitHub ↗

r"""Copy a file or directory to the container. Args: source (str): The local path to the file. dest (str): The path to copy the file to in the container. Returns: DockerRuntime: The DockerRuntime instance.

(self, source: str, dest: str)

Source from the content-addressed store, hash-verified

103 return self
104
105 def copy(self, source: str, dest: str) -> "DockerRuntime":
106 r"""Copy a file or directory to the container.
107
108 Args:
109 source (str): The local path to the file.
110 dest (str): The path to copy the file to in the container.
111
112 Returns:
113 DockerRuntime: The DockerRuntime instance.
114 """
115 _source, _dest = Path(source), Path(dest)
116 if not _source.exists():
117 raise FileNotFoundError(f"Source {_source} does not exist.")
118
119 self.cp[_source] = _dest
120 return self
121
122 def add_task(
123 self,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected