Containerize your Development with VS Code Dev Containers

Поділитися
Вставка
  • Опубліковано 10 лют 2025
  • Use VS Code Dev Containers to containerize your workflow!
    code.visualstu...
    This video is now cross-posted as a blog article!
    willwill96.git...

КОМЕНТАРІ • 11

  • @408sophon
    @408sophon 2 роки тому

    Nice explanation, ez sub! Really appreciate the calm and considered presentation

  • @rdmccray
    @rdmccray Рік тому +2

    So I am new to programming. What I am struggling with is the source code. Where does it reside? Inside the container? How do we manage it? Git inside the container? Any help would be appreciated.

    • @theuidawg3274
      @theuidawg3274  Рік тому +2

      The ".devcontainer" folder typically lives alongside your source code. Devcontainers aren't technically opinionated on the the way you manage your code, but git is definitely the industry standard. VS Code mounts your code inside of the container, meaning changes should be reflected both inside and out of the container. I typically use my git commands from within the container, but either way should work fine. I think this is the most minimal example of a repo using devcontainers in case your looking for an example: github.com/willwill96/simple-web-scraper
      Let me know if I can clarify anything else for you and welcome to programming!

    • @aurelienboubennec739
      @aurelienboubennec739 Рік тому

      @@theuidawg3274 thank you for the clarification!

  • @theo5784
    @theo5784 2 роки тому +1

    Thank you very much man

  • @ValeriPenchev
    @ValeriPenchev Рік тому

    This video is in a chrome tab for more than a month... Today was the day to watch it I can see that I have learned something new!
    Thank you very much!
    I have a question - is that going to be so easy to setup java dev container? What is your opinion?

    • @theuidawg3274
      @theuidawg3274  Рік тому

      I haven't set it up, but it should be just as simple to setup java because they have a predefined template for it 🙂. If you need a build tool like maven, it looks a bit more config involved to setup but they do have instructions. UA-cam doesn't allow links in comments, but if you Google "maven vs code devcontainers" I think you can find it - it should be a markdown file in their repo.
      I love using devcontainers for trying out new languages, because it lets you skip the entire installation setup.

    • @ValeriPenchev
      @ValeriPenchev Рік тому +1

      @@theuidawg3274 i found the templates, there is one for java container. I will try my luck with it!
      Thank you!

  • @lcui4813
    @lcui4813 2 роки тому +1

    useful,thanks

  • @thelamarcke
    @thelamarcke 2 роки тому +1

    Nice video. I like how calm your voice is lol.
    Do you think it's also possible to setup this in Jetbrains IDEs? I've been having a hard time even making them work with WSL, and adding Docker on top of that... VS Code is miles ahead, at least for now.

    • @theuidawg3274
      @theuidawg3274  2 роки тому

      Thanks! I don't think jetbrains has something as fully featured as this yet, although last I checked they have a ticket open to implement it.
      You could probably get a partial implementation by running docker manually and forwarding the right ports to make remote debug work. It would be a bit hacky though.