‫OK. Now that we've learned how to add build environment configurations to our compose file, we're going
‫to start an assignment that is going to build on the last assignment.
‫We're going to use the same compose file you had before. This time, we're actually going to create
‫a custom, Drupal image from the official repository, and we're going to add some stuff to it.
‫The scenario here would be is that you're not actually a developer this time.
‫Maybe you're a sysadmin, or maybe you're a software tester, or maybe you're just wanting to learn Drupal and
‫you just want to be a Drupal admin. Docker is great for that, too.
‫Compose can really make things so much easier.
‫If you can imagine before, just a few years ago, if you had a Mac or Windows machine and someone said,
‫'hey, you need to learn Drupal,' now you've got to get postgres or MySQL installed. Then you've
‫got to get PHP and Apache installed. Then you got to get Drupal installed and all the modules that go
‫with it.
‫Then the templating. You know, it just it goes on and on. The complexity there really discourages
‫people from actually trying to run it themselves, which is a shame.
‫Compose solves that problem for those people, and you might be one of them, where you just want to
‫run a piece of software to use it.
‫You don't want to develop on it.
‫You're not trying to change it. You just want to try it.
‫But the complexity of getting it running was so much before, that it would discourage some people from
‫even trying it.
‫Again, we're going to start with your compose file that you built in the previous assignment for this
‫section. We're going to create a Dockerfile first, that is a custom image of a Drupal, with a template added
‫in it.
‫Basically, all we're doing here is we're creating the same thing as before, only we're going to build
‫that Dockerfile with a bootstrap template. That's the name of the template, and it's going to allow you to
‫add the template into the GUI of Drupal.
‫This really isn't about learning Drupal.
‫Obviously, we're here to learn Docker.
‫But I wanted you to go through this exercise of understanding how this could be useful for someone who is
‫not a developer. And how we can add build environment options to our Compose so that we can still just
‫do the single, one line, docker compose up, just like we did before, but now it's actually on the fly building
‫images if it needs them.
‫We're going to use Drupal and postgres just like before.
‫Inside our Repo, the compose assignment 2 directory, will have a readme, and you're going to use the
‫compose file.
‫Hope you saved it from last time.
‫You're going to put that in there.
‫Then also build a Dockerfile. Then follow the instructions in the readme.
‫I'm just going to pull up that readme real quick so we can just quickly review it.
‫OK. As you can see, it's actually quite wordy. I tried to give you as much information as I could
‫without completely answering the whole thing for you.
‫Most of the lines for the Dockerfile are in here.
‫It should be very explicit about exactly what you have to do. Then you're using the compose file before
‫and you're only changing a few lines of it.
‫Of course, if you get stuck or you just want to see how I would do it, watch the next lecture.
‫You can watch me run through it as I would do it. Hopefully, you'll take a few minutes and give this a try
‫and have some fun.