Skip to content

PhilipNelson5/devcontainer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Devcontainer snippets and helpful tips

Install various software from source code or precompiled binaries


Create a persistent home directory to maintain personal configuration between new instances of the devcontainer by mounting a docker volume as the home directory.


Orchestrate multiple containers to create a complex development environment using docker-compose;


Mount a unique out of source build directory so that repositories in the same host directory do not conflict.

  "mounts": [
    "source=${localWorkspaceFolder}/../${localWorkspaceFolderBasename}-build,target=/workspaces/build,type=bind,consistency=delegated",
  ],

If you need to use a ptrace based debugger for C++, Go, Rust, etc.

  "runArgs": [
    "--cap-add=SYS_PTRACE",
    "--security-opt",
    "seccomp=unconfined",
  ]

If you need access to host docker from inside the container

  "runArgs": [
    "--privileged",
    "-v",
    "/var/run/docker.sock:/run/docker.sock",
  ]

If you need your container on a special docker network

  "runArgs": [
    "--network=<name>",
  ]

If you have a local X11 server and want to run a graphical application inside the container

export DISPLAY=host.docker.internal:0.0

About

Configurations and settings for devcontainers

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published