title: How to get the numeric exit status of an exited docker container?
body: <p>When a container exits, <code>docker ps -a</code> shows its exit code (scroll</p>
  
  <pre><code>$ docker run ubuntu bash -c "exit 1"
  CONTAINER ID   IMAGE    COMMAND              CREATED        STATUS                     PORTS                     NAMES
  c2c769c4b9ef   ubuntu   "bash -c 'exit 1'"   6 seconds ago  Exited (1) 3 seconds ago                             happy_fermat
  </code></pre>
  
  <p><strong>How do I get the numeric exit code programmatically, without error-prone <code>grep</code>-ing and <code>cut</code>-ing?</strong></p>