Image

Customize an Existing Image

Often you'll find an image on Docker Hub that almost fits your requirements. For Drupal developers, often the off-the-shelf containers for PHP just aren't enough. Drupal often requires additional PHP extensions such as mbstring or gd. We may also want to use a slightly different configuration, or bake-in a utility like Drush or Drupal Console. Fortunately, Docker makes modifying existing containers easy in a Dockerfile.

In this tutorial, we'll:

  • List the reasons why you might modify an existing image
  • Describe the general process by which an existing image is modified