cli
cli copied to clipboard
Ctrl-C on fn start behaviour inconsistent
After running fn start
in the foreground, Ctrl-C'ing the process sometimes stops the functions container and sometimes leaves it running. Working with new users I've seen them interrupting fn start
and then reissuing the command only to be told the container 'functions' is already running. To avoid making casual users learn Docker, I suggest a few enhancements:
- Ctrl-C/SIGINT to
fn start
should shut down the functions container - If someone issues
fn start
and the functions container is already running it should fail with an appropriate user friendly error message. - Either add an argument to
fn start
like-f(orce)
or addfn restart
to shut down the current functions container and start a new one. I think "restart" is more explicit and would be the advice provided when the user tries to use "start" when a functions container is already running.
i've noticed this also. ctrl-c feels like it should shut down but sometimes the container keeps running.