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

feat: support '--detach-keys' for 'nerdctl (run|start)' #2128

Merged
merged 1 commit into from
Jun 11, 2023

Commits on Jun 8, 2023

  1. feat: support '--detach-keys' for 'nerdctl (run|start)'

    Control flow:
    
    1. Detect if the detach keys are present in stdin.
    2. After detecting the detach keys, cancel the current I/O operations by calling IO.Cancel().
       This means that the underlying I/O FIFOs should be left intact,
       and containerd should keep writing to/reading from those FIFOs,
       but nerdctl should stop writing to/reading from them.
    3. After starting the task, we need to call IO.Wait(), and after it returns,
       we need to see if the container exits or it's just the user detaching from the container
       by checking the state of the container.
    
    Signed-off-by: Hsing-Yu (David) Chen <davidhsingyuchen@gmail.com>
    davidhsingyuchen committed Jun 8, 2023
    Configuration menu
    Copy the full SHA
    ec49140 View commit details
    Browse the repository at this point in the history