mirror of
https://github.com/containers/podman.git
synced 2025-07-18 01:57:24 +08:00
Merge pull request #21724 from rhatdan/docs11
[CI:DOCS] Fix up example description of podman-cp.1.md
This commit is contained in:
@ -101,32 +101,32 @@ the cp command.
|
|||||||
|
|
||||||
## EXAMPLES
|
## EXAMPLES
|
||||||
|
|
||||||
- Copy a file from host to a container.
|
Copy a file from the host to a container:
|
||||||
```
|
```
|
||||||
podman cp /myapp/app.conf containerID:/myapp/app.conf
|
podman cp /myapp/app.conf containerID:/myapp/app.conf
|
||||||
```
|
```
|
||||||
|
|
||||||
- Copy a file from a container to a directory on another container.
|
Copy a file from a container to a directory on another container:
|
||||||
```
|
```
|
||||||
podman cp containerID1:/myfile.txt containerID2:/tmp
|
podman cp containerID1:/myfile.txt containerID2:/tmp
|
||||||
```
|
```
|
||||||
|
|
||||||
- Copy a directory on a container to a directory on the host.
|
Copy a directory on a container to a directory on the host:
|
||||||
```
|
```
|
||||||
podman cp containerID:/myapp/ /myapp/
|
podman cp containerID:/myapp/ /myapp/
|
||||||
```
|
```
|
||||||
|
|
||||||
- Copy the contents of a directory on a container to a directory on the host.
|
Copy the contents of a directory on a container to a directory on the host:
|
||||||
```
|
```
|
||||||
podman cp containerID:/home/myuser/. /home/myuser/
|
podman cp containerID:/home/myuser/. /home/myuser/
|
||||||
```
|
```
|
||||||
|
|
||||||
- Copy a directory on a container into a directory on another.
|
Copy a directory on a container into a directory on another:
|
||||||
```
|
```
|
||||||
podman cp containerA:/myapp containerB:/newapp
|
podman cp containerA:/myapp containerB:/newapp
|
||||||
```
|
```
|
||||||
|
|
||||||
- Stream a tar archive from `STDIN` to a container.
|
Stream a tar archive from `STDIN` to a container:
|
||||||
```
|
```
|
||||||
podman cp - containerID:/myfiles.tar.gz < myfiles.tar.gz
|
podman cp - containerID:/myfiles.tar.gz < myfiles.tar.gz
|
||||||
```
|
```
|
||||||
|
Reference in New Issue
Block a user