Build parent images checking the Dockerfile directive

 Fixes #1