The nohup command
run a command immune to hangups, with output to a non-tty 2 examples from the lessons of the IVski Linux Playground — try them in the terminal next to them.
Examples
nohup command &Run even after logout
nohup python3 server.py > server.log &