1podman-attach(1)() 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 "" will disable this feature.
32 The default is ctrl-p,ctrl-q.
33
34
35 --latest, -l
36 Instead of providing the container ID or name, use the last created
37 container. If other methods than Podman are used to run containers such
38 as CRI-O, the last started container could be from either of those
39 methods.
40 The default is false.
41 IMPORTANT: This OPTION is not available with the remote Podman client,
42 including Mac and Windows (excluding WSL2) machines. This OPTION does
43 not need a container name or ID as input argument.
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 process (non-TTY mode only). SIGCHLD,
52 SIGSTOP, and SIGKILL are not proxied.
53 The default is true.
54
55
57 Attach to a container called "foobar".
58
59
60 $ podman attach foobar
61
62
63
64 Attach to the latest created container.
65
66
67 $ podman attach --latest
68
69
70
71 Attach to a container that start with the ID "1234".
72
73
74 $ podman attach 1234
75
76
77
78 Attach to a container without attaching STDIN.
79
80
81 $ podman attach --no-stdin foobar
82
83
84
86 podman(1), podman-exec(1), podman-run(1), containers.conf(5)
87
88
89
90 podman-attach(1)()