1podman-attach(1) General Commands Manual podman-attach(1)
2
3
4
6 podman-attach - Attach to a running container
7
8
10 podman attach [options] container
11
12
13 podman container attach [options] container
14
15
17 podman attach attaches to a running container using the container's
18 name or ID, to either view its ongoing output or to control it interac‐
19 tively.
20 The container can be detached from (and leave it running) using a con‐
21 figurable key sequence. The default sequence is ctrl-p,ctrl-q. Config‐
22 ure the keys sequence using the --detach-keys OPTION, or specifying it
23 in the containers.conf file: see containers.conf(5) for more informa‐
24 tion.
25
26
28 --detach-keys=sequence
29 Specify the key sequence for detaching a container. Format is a single
30 character [a-Z] or one or more ctrl-<value> characters where <value> is
31 one of: a-z, @, ^, [, , or _. Specifying "" disables this feature. The
32 default is ctrl-p,ctrl-q.
33
34
35 This option can also be set in containers.conf(5) file.
36
37
38 --latest, -l
39 Instead of providing the container name or ID, use the last created
40 container. Note: the last started container can be from other users of
41 Podman on the host machine. (This option is not available with the re‐
42 mote Podman client, including Mac and Windows (excluding WSL2) ma‐
43 chines)
44
45
46 --no-stdin
47 Do not attach STDIN. The default is false.
48
49
50 --sig-proxy
51 Proxy received signals to the container process. SIGCHLD, SIGURG,
52 SIGSTOP, and SIGKILL are not proxied.
53
54
55 The default is true.
56
57
59 Attach to a container called "foobar".
60
61 $ podman attach foobar
62
63
64
65 Attach to the latest created container.
66
67 $ podman attach --latest
68
69
70
71 Attach to a container that start with the ID "1234".
72
73 $ podman attach 1234
74
75
76
77 Attach to a container without attaching STDIN.
78
79 $ podman attach --no-stdin foobar
80
81
82
84 podman(1), podman-exec(1), podman-run(1), containers.conf(5)
85
86
87
88 podman-attach(1)