Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Detaching from container doesn't print newline #7751

Closed
mohd-akram opened this issue Sep 23, 2020 · 12 comments
Closed

Detaching from container doesn't print newline #7751

mohd-akram opened this issue Sep 23, 2020 · 12 comments
Assignees
Labels
Good First Issue This issue would be a good issue for a first time contributor to undertake. In Progress This issue is actively being worked by the assignee, please do not work on this at this time. kind/bug Categorizes issue or PR as related to a bug. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.

Comments

@mohd-akram
Copy link

Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)

/kind bug

Description

Steps to reproduce the issue:

  1. Run podman run -it fedora /bin/bash

  2. Press ctrl-p ctrl-q to detach

Describe the results you received:

[root@6aef033eef57 /]# [user@host ~]$

Describe the results you expected:

[root@6aef033eef57 /]# read escape sequence
[user@host ~]$

Additional information you deem important (e.g. issue happens only occasionally):

On Docker, the additional message is printed to stderr.

Output of podman version:

2.0.6

Output of podman info --debug:

host:
  arch: amd64
  buildahVersion: 1.15.1
  cgroupVersion: v2
  conmon:
    package: conmon-2.0.19-1.fc32.x86_64
    path: /usr/bin/conmon
    version: 'conmon version 2.0.19, commit: 5dce9767526ed27f177a8fa3f281889ad509fea7'
  cpus: 8
  distribution:
    distribution: fedora
    version: "32"
  eventLogger: file
  hostname: razrlab-am
  idMappings:
    gidmap:
    - container_id: 0
      host_id: 1000
      size: 1
    - container_id: 1
      host_id: 100000
      size: 65536
    uidmap:
    - container_id: 0
      host_id: 1000
      size: 1
    - container_id: 1
      host_id: 100000
      size: 65536
  kernel: 5.8.7-200.fc32.x86_64
  linkmode: dynamic
  memFree: 679784448
  memTotal: 15745339392
  ociRuntime:
    name: crun
    package: crun-0.14.1-5.fc32.x86_64
    path: /usr/bin/crun
    version: |-
      crun version 0.14.1
      commit: 598ea5e192ca12d4f6378217d3ab1415efeddefa
      spec: 1.0.0
      +SYSTEMD +SELINUX +APPARMOR +CAP +SECCOMP +EBPF +YAJL
  os: linux
  remoteSocket:
    path: /run/user/1000/podman/podman.sock
  rootless: true
  slirp4netns:
    executable: /usr/bin/slirp4netns
    package: slirp4netns-1.1.4-1.fc32.x86_64
    version: |-
      slirp4netns version 1.1.4
      commit: b66ffa8e262507e37fca689822d23430f3357fe8
      libslirp: 4.3.1
      SLIRP_CONFIG_VERSION_MAX: 2
  swapFree: 4345999360
  swapTotal: 7944007680
  uptime: 218h 43m 4.09s (Approximately 9.08 days)
registries:
  search:
  - registry.fedoraproject.org
  - registry.access.redhat.com
  - registry.centos.org
  - docker.io
store:
  configFile: /home/mohamed/.config/containers/storage.conf
  containerStore:
    number: 4
    paused: 0
    running: 3
    stopped: 1
  graphDriverName: overlay
  graphOptions:
    overlay.mount_program:
      Executable: /usr/bin/fuse-overlayfs
      Package: fuse-overlayfs-1.1.2-1.fc32.x86_64
      Version: |-
        fusermount3 version: 3.9.1
        fuse-overlayfs: version 1.1.0
        FUSE library version 3.9.1
        using FUSE kernel interface version 7.31
  graphRoot: /home/mohamed/.local/share/containers/storage
  graphStatus:
    Backing Filesystem: extfs
    Native Overlay Diff: "false"
    Supports d_type: "true"
    Using metacopy: "false"
  imageStore:
    number: 4
  runRoot: /run/user/1000/containers
  volumePath: /home/mohamed/.local/share/containers/storage/volumes
version:
  APIVersion: 1
  Built: 1598988411
  BuiltTime: Tue Sep  1 23:26:51 2020
  GitCommit: ""
  GoVersion: go1.14.6
  OsArch: linux/amd64
  Version: 2.0.6

Package info (e.g. output of rpm -q podman or apt list podman):

podman-2.0.6-1.fc32.x86_64

Have you tested with the latest version of Podman and have you checked the Podman Troubleshooting Guide?

No

Additional environment details (AWS, VirtualBox, physical, etc.):

Physical laptop.

@openshift-ci-robot openshift-ci-robot added the kind/bug Categorizes issue or PR as related to a bug. label Sep 23, 2020
@rhatdan rhatdan added the Good First Issue This issue would be a good issue for a first time contributor to undertake. label Sep 24, 2020
@rhatdan
Copy link
Member

rhatdan commented Sep 24, 2020

Interested in opening a PR to fix this?

@mohd-akram
Copy link
Author

How do I build without make package-install (I don't want to run sudo)?. I get this with make:

# Only generate the varlink code on Linux (see issue #4814).
GO111MODULE=off go generate ./pkg/varlink/...
../../vendor/github.com/varlink/go/cmd/varlink-go-interface-generator/main.go:12:2: cannot find package "github.com/varlink/go/varlink/idl" in any of:
        /usr/lib/golang/src/github.com/varlink/go/varlink/idl (from $GOROOT)
        /home/mohamed/Downloads/podman/_output/src/github.com/varlink/go/varlink/idl (from $GOPATH)
pkg/varlink/generate.go:3: running "go": exit status 1
make: *** [Makefile:646: pkg/varlink/iopodman.go] Error 1

@ParkerVR
Copy link
Collaborator

@mohd-akram I'll take a look at this.
It's not recommended to install podman without sudo privileges but you can consider using nix as in the guide
https://podman.io/getting-started/installation and installing any failing dependencies manually.

@ParkerVR ParkerVR self-assigned this Sep 28, 2020
@ParkerVR ParkerVR added the In Progress This issue is actively being worked by the assignee, please do not work on this at this time. label Sep 28, 2020
@ParkerVR
Copy link
Collaborator

@mohd-akram I'm getting identical results in both Docker and Podman on both 2.0.6 and upstream. can you clarify what exactly you're seeing differently?

@mohd-akram
Copy link
Author

It's described in the issue. What is the result you're getting?

@ParkerVR
Copy link
Collaborator

➜ ~ podman run -it fedora /bin/bash
[root@1509726a4eeb /]# %
➜ ~ sudo docker run -it fedora /bin/bash
[root@a6e4cffd2cea /]# %
➜ ~

@mohd-akram
Copy link
Author

Try this:

docker create -it --name fedora fedora
docker start fedora
docker attach fedora
<ctrl-p> <ctrl-q>

@rhatdan
Copy link
Member

rhatdan commented Oct 5, 2020

@ParkerVR Any progress on this?

@ParkerVR
Copy link
Collaborator

ParkerVR commented Oct 7, 2020

@rhatdan I made two PRs for this - one that is strictly the Docker compatible style and another that is internally consistent and prints a newline on detaches, let me know what you think

@rhatdan
Copy link
Member

rhatdan commented Oct 10, 2020

It is probably better we follow Docker.

@ParkerVR
Copy link
Collaborator

@rhatdan the non-docker edition got merged in. If you want the Docker style I can update that PR to undo the other change, otherwise I will continue with the current detach method and test on the other cases brought up

@rhatdan
Copy link
Member

rhatdan commented Oct 13, 2020

Ok I am fine with this as long as users don't complain. Can we close this issue?

@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 22, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 22, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Good First Issue This issue would be a good issue for a first time contributor to undertake. In Progress This issue is actively being worked by the assignee, please do not work on this at this time. kind/bug Categorizes issue or PR as related to a bug. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.
Projects
None yet
Development

No branches or pull requests

4 participants