To keep a container running in the background, supply the
-d command line option during container startup:
docker run -d busybox top
-d runs the container in detached mode. It is also equivalent to
A container in detached mode cannot be removed automatically when it stops, this means one cannot use the --rm option in combination with -d option.