Sometimes, containers die, and you need to look inside to resolve, this one liner allows a quick way to adjust the 'container_name' and it will drop you right into the container so you can look around, then cleanup afterwards.

CTR="container_name"; docker commit $(docker ps -a | egrep " ${CTR}$" | awk '{ print $1 }') test; docker run --rm -ti --entrypoint=bash test; docker rmi test

Or maybe as a script, something like:

#!/bin/bash

docker commit $(docker ps -a | egrep " $1\$" | awk '{ print $1 }') test
docker run --rm -ti --entrypoint=bash test
docker rmi test