Simplify All the Things with Docker Compose

Sdílet
Vložit
  • čas přidán 13. 08. 2020
  • --
    As you probably know by now, containers have revolutionized the software industry. But, once you have a container, then what? How do you run it? How do you help someone else run it? There are so many flags and options to remember, ports to configure, volume mappings to remember, and don't even get me started with networking containers together! While it's possible to do all of this through the command line, don't do it that way! With Docker Compose, you can create an easily shareable file that makes all of this a piece of cake. And once you fully adopt containers in your dev environment, it lets you setup your code repos to allow the simplest dev onboarding experience imaginable: 1) git clone; 2) docker-compose up; 3) write code.
    In this talk, we'll talk about several tips to help make all of this a reality. We'll start with a few Docker Compose basics, but then quickly move into several advanced topics. We'll even talk about how to use the same Dockerfile for dev and prod (we've all been there by having two separate files)! As an added bonus, we'll look at how to use Docker Compose in our CI/CD pipelines to perform automated tests of the container images built earlier in the pipeline!
    We'll have a few slides (because we have to explain a few things), lots of live demos (show it in action!), and maybe a few other surprises as well! Let's have some fun and help simplify all the things with Docker Compose!
    Speaker: Michael Irwin, Virginia Tech
    Twitter: @mikesir87
  • Věda a technologie

Komentáře • 31

  • @viseshprasad
    @viseshprasad Před 4 lety +4

    a college class on containers? Hell yeah! Excellent talk. Thanks!

  • @iabierta
    @iabierta Před 4 lety +4

    Thanks indeed, found your speech quite clear and illustrative

  • @daviddonadze221
    @daviddonadze221 Před 2 lety +2

    Thanks man. Million thanks

  • @ginxo
    @ginxo Před 4 lety +2

    Congrats @Michael! Very easy to follow! I didn't know about stages and how useful they can be. I also liked the configuration about proxy & app. Thanks man!!!

    • @mikesir87
      @mikesir87 Před 4 lety

      You're quite welcome! I'm glad you found it useful!

  • @rayusaki88
    @rayusaki88 Před 3 lety +2

    Thanks Mike! Very helpful.

  • @keerthikaj
    @keerthikaj Před 2 lety

    Great talk with good demo.. Thanks a lot.

  • @pratik_chuckles
    @pratik_chuckles Před 3 lety +2

    super insightful!

  • @georgestatefield
    @georgestatefield Před 3 lety +2

    Thank you for tutorial!

  • @MelissaKippPlusHomeschool

    Thank you for all the resources!!! super helpful

    • @mikesir87
      @mikesir87 Před 4 lety +1

      Thanks for the comment and for tuning in! :)

  • @fawadullahkhan
    @fawadullahkhan Před rokem

    Amazing tutorial. thanks for the effort

  • @brianalmaguer1525
    @brianalmaguer1525 Před 3 lety +2

    Love it. One of the best structured intermediate level talks I have ever seen. This definitely scratched my information itch.

  • @Strannik20111
    @Strannik20111 Před 4 lety +2

    Awesome talk

  • @heavysavage5931
    @heavysavage5931 Před rokem

    Thaats briliant. Thanks!!

  • @manuelgonzalotoribioruizal1416

    Thank you Michael
    It was clear and easy to understand everything you talked about.
    But I taste a feel that there are deep things to learnn that you only mention in the video.
    Perhaps ask you from your time prepare a video with those things.
    Thank you a lot

  • @teeodoubled3000
    @teeodoubled3000 Před 3 lety +2

    Great talk! I'm newer to docker and understand the concept of mapping a local directory to a directory in the image so you use your local files to do development... In your docker compose file you have the named volume "nodemodules" that's mapped to the /node_modules directory in the image. What is that doing within your dev environment if it's not linked to the /node_modules in your local directory?

    • @mikesir87
      @mikesir87 Před 3 lety +1

      I know it's been a while, but this was a commonly used technique to help speed things up. The node_modules has a ton of files in it, so suffered from filesystem speed issues. By using a module to store the files, it kept all of the files in the Docker vm, skipping the sync and making things faster. The downside (which is fairly major) is that the files aren't synced back into the host, so IDEs can't intelligently help you with auto-imports, etc. But, with recent updates to the file syncing in Docker Desktop, I definitely wouldn't do this anymore. Great question and observation!

    • @teeodoubled3000
      @teeodoubled3000 Před 3 lety

      @@mikesir87 Thank you for taking the time to explain!

  • @volkruss
    @volkruss Před 3 lety +2

    -1 for white theme on VS Code though (just kidding). Thanks a lot for this presentation.

    • @mikesir87
      @mikesir87 Před 2 lety +1

      Haha! I don't normally use a white theme, but white backgrounds tend to be easier to see in recordings/presentations. 😉

  • @iranicus
    @iranicus Před rokem

    Moving the project I work on at work towards becoming dockerised, at the moment the devs and testers just run the code in the terminal using maven (Spring Boot 2 Java 11 app). There's about 6 services that need starting in a particular order so multiple commands required per service. Created the Dockerfiles for each of them already and now a single docker compose yaml to run them all in one command. Way easier and quicker to get them setup now, just need to get it approved by the tech lead 👌. I was wondering though, should the docker compose file have its own git repo?

    • @piusjohn-tl8cs
      @piusjohn-tl8cs Před měsícem

      wow!! can i get the source code for this architecture
      just wanna try it out

  • @pingyang8963
    @pingyang8963 Před 4 lety +2

    Will you share the github for this presentation?

    • @mikesir87
      @mikesir87 Před 4 lety +1

      Absolutely! Here ya go: github.com/mikesir87/dockercon-2020-compose-talk

    • @pingyang8963
      @pingyang8963 Před 4 lety

      @@mikesir87 Thank you very much. I have issue on running this 'docker-compose -f docker-compose-test.yml -p tests up --exit-code-from tests', it prompted me to log in the docker hub, I did input my username and password, I still got the error "pull access denied for dc2020, repository does not exist or may require 'docker login': denied: requested access to the resource is denied", how to fix this?

    • @mikesir87
      @mikesir87 Před 4 lety +1

      @@pingyang8963 Ah! The images were only locally built and aren't on Docker Hub. If you run "docker build -t dc2020 ." to build the app image and then a "docker build -t dc2020-tests -f Dockerfile-e2e ." to build the test image, it should then work. I probably should have mentioned that somewhere. Sorry about that!

  • @Salahudin-
    @Salahudin- Před 2 lety +2

    So.. was it a boy or a girl?

  • @kirdiekirdie
    @kirdiekirdie Před 2 lety

    Great video but a bit too much personal information at the beginning, I think most of the audience just wants to hear about the topic and not you marital status and so on.

  • @thecosmicantinatalist
    @thecosmicantinatalist Před 2 lety +3

    What the hell! 5 kids? Use some contraception dear.