From 0e2cce5af13a31a7bad3225c92ad484379a2c609 Mon Sep 17 00:00:00 2001 From: Chuck Lantz Date: Wed, 3 Apr 2019 10:21:43 -0700 Subject: [PATCH 1/7] .vscode/devContainer.json => .devcontainer/devcontainer.json --- CONTRIBUTING.md | 7 +++---- README.md | 12 ++++++------ .../devcontainer.json} | 0 containers/azure-cli/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 .../azure-functions-node-8/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 .../azure-hdinsight-python-3/.devcontainer/ignore | 2 -- .../.devcontainer/ignore | 2 -- .../.vscode/devContainer.json | 8 -------- .../devcontainer.json} | 0 containers/azure-terraform/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/cpp/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/dart-web/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 .../.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 .../docker-existing-dockerfile/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 .../docker-in-docker-compose/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/docker-in-docker/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 .../dotnetcore-2.2-fsharp/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/dotnetcore-2.2/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/go/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/java-8-maven/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 .../javascript-node-8-mongo/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/javascript-node-8/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/kubernetes-helm/.devcontainer/ignore | 2 -- containers/latex/.devcontainer/ignore | 5 ----- containers/latex/.vscode/devContainer.json | 7 ------- containers/latex/README.md | 5 ----- .../devcontainer.json} | 0 containers/markdown/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/php-7/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/plantuml/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/powershell/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/python-2/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/python-3-django/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/python-3-flask-redis/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 .../python-3-jupyter-pyspark/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/python-3/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/ruby-2/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/rust/.devcontainer/ignore | 2 -- .../devcontainer.json} | 0 containers/swift-4/.devcontainer/ignore | 9 +++------ .../devcontainer.json} | 0 containers/typescript-node-8/.devcontainer/ignore | 2 -- 67 files changed, 12 insertions(+), 101 deletions(-) rename containers/azure-cli/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/azure-functions-node-8/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/azure-hdinsight-python-3/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) delete mode 100644 containers/azure-machine-learning-python-3/.vscode/devContainer.json rename containers/azure-terraform/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/cpp/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/dart-web/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/docker-existing-docker-compose/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/docker-existing-dockerfile/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/docker-in-docker-compose/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/docker-in-docker/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/dotnetcore-2.2-fsharp/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/dotnetcore-2.2/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/go/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/java-8-maven/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/javascript-node-8-mongo/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/javascript-node-8/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/kubernetes-helm/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) delete mode 100644 containers/latex/.devcontainer/ignore delete mode 100644 containers/latex/.vscode/devContainer.json delete mode 100644 containers/latex/README.md rename containers/markdown/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/php-7/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/plantuml/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/powershell/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/python-2/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/python-3-django/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/python-3-flask-redis/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/python-3-jupyter-pyspark/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/python-3/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/ruby-2/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/rust/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/swift-4/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) rename containers/typescript-node-8/{.vscode/devContainer.json => .devcontainer/devcontainer.json} (100%) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 72a27d927b..ad4727a0c1 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -100,9 +100,8 @@ If you want to create a new definition: ``` 📁 -- - 📁 .vscode - 📄 devContainer.json 📁 .devcontainer + 📄 devcontainer.json 📄 Dockerfile (optional) 📄 docker-compose.yml (optional) 📄 ignore @@ -110,7 +109,7 @@ If you want to create a new definition: 📄 README.md ``` - See the [VS Code Remote Development documentation](https://aka.ms/vscode-remote/docker) for information on the expected contents of `devContainer.json` and how it relates to other files listed above. + See the [VS Code Remote Development documentation](https://aka.ms/vscode-remote/docker) for information on the expected contents of `devcontainer.json` and how it relates to other files listed above. Note that any additional assets can be included as needed, but keep in mind that these will overlay on top of an existing project. Keeping these files in the `.devcontainer` should reduce the chances of something conflicting but note that any command that are run are relative to the root of the project, so you'll need to include `.devcontainer` in any path references. @@ -136,7 +135,7 @@ Finally, after you get your container up and running, you can test it by adding While using a `Dockerfile` is a convienent way to get going with a new container definition, this method can slow down the process of creating the dev container since it requires the image be built by anyone using it. If your definition is stable, we strongly reccomend building and publishing your image to [DockerHub](https://hub.docker.com) or [Azure Container Registry](https://azure.microsoft.com/en-us/services/container-registry/) instead. -Once you've published your container image, just update `devContainer.json` to reference the image instead of the `Dockerfile`. See `container-templates/image` for an example. +Once you've published your container image, just update `devcontainer.json` to reference the image instead of the `Dockerfile`. See `container-templates/image` for an example. ## Contributing to Documentation diff --git a/README.md b/README.md index 2445511e5e..26de7e4ee6 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ Visual Studio Code Remote allows you to open any folder inside (or mounted into) **[See here to learn more about VS Code Remote](https://aka.ms/vscode-remote/containers)**. -This repository contains a set of **dev container definitions** made up of files like `devContainer.json` to help get you up and running in a containerized environment. These definitions describe the needed container image, any runtime arguments for starting the container, and any VS Code extensions that should be installed into it. +This repository contains a set of **dev container definitions** made up of files like `devcontainer.json` to help get you up and running in a containerized environment. These definitions describe the needed container image, any runtime arguments for starting the container, and any VS Code extensions that should be installed into it. ## Trying a definition @@ -24,15 +24,15 @@ You can either: - Run **Remote: Create Container Configuration File...** command in VS Code and pick a definition. The appropriate files will then be added to your project. -- Manually copy the contents of one of the `containers` sub-folders into your project. Copy the `.devcontainer` folder and `.vscode/devContainer.json` into your project and you should be ready to go! +- Manually copy the contents of one of the `containers` sub-folders into your project. Copy the `.devcontainer` folder into your project and you should be ready to go! ### Can I just reuse an existing Docker configuration? Absolutely! If you want to use an existing Dockerfile as a starting point, run **Remote-Containers: Create Container Configuration File...** from the command pallette (Cmd/Ctrl+Shift+P). You'll be prompted to select a Dockerfile or you can opt to use a base image instead. -#### About `.vscode/devContainer.json` +#### About `.devcontainer/devcontainer.json` -The intent of `devContainer.json` is conceptually similar to VS Code's `launch.json` for debugging, but designed to launch (or attach to) your development container instead. At its simplest, all you need to do is add a `.vscode/devContainer.json` file to your project and reference an image, `Dockerfile`, or `docker-compose.yml`. +The intent of `devcontainer.json` is conceptually similar to VS Code's `launch.json` for debugging, but designed to launch (or attach to) your development container instead. At its simplest, all you need to do is add a `.devcontainer/devcontainer.json` file to your project and reference an image, `Dockerfile`, or `docker-compose.yml`. Since you are here, check out the [existing Dockerfile](containers/docker-existing-dockerfile) and [existing Docker Compose](containers/docker-existing-docker-compose) definitions for details, but here's the a quick tour of the basic properties. If you have a `Dockerfile`, set these properties: @@ -43,7 +43,7 @@ Since you are here, check out the [existing Dockerfile](containers/docker-existi } ``` -For Docker Compose, you can [attach to an already running container](https://aka.ms/vscode-remote/containers/attach) or configure `.vscode/devContainer.json` with these properties: +For Docker Compose, you can [attach to an already running container](https://aka.ms/vscode-remote/containers/attach) or configure `.devcontainer/devcontainer.json` with these properties: ```json { @@ -60,7 +60,7 @@ The other definitions in the `containers` folder will provide examples of how to ## Adding a definition to an existing public or private repo -You can easily share a customized dev container definition for your project by simply adding files like `.vscode/devContainer.json` to source control. By including these files in your repository, anyone that opens a local copy of your repo in VS Code will be automatically asked if they want reopen the folder in a container instead if the [Remote Development](https://aka.ms/vscode-remote/download/extension) extension installed. +You can easily share a customized dev container definition for your project by simply adding files like `.devcontainer/devcontainer.json` to source control. By including these files in your repository, anyone that opens a local copy of your repo in VS Code will be automatically asked if they want reopen the folder in a container instead if the [Remote Development](https://aka.ms/vscode-remote/download/extension) extension installed. Beyond the advantages of having your team use a consistent environment and tool-chain, doing this can make it easier for new contributors or team members to get productive quickly. First-time contributors will require less guidance and are less likely to either submit issues or contribute code with issues that are related to environment setup. diff --git a/containers/azure-cli/.vscode/devContainer.json b/containers/azure-cli/.devcontainer/devcontainer.json similarity index 100% rename from containers/azure-cli/.vscode/devContainer.json rename to containers/azure-cli/.devcontainer/devcontainer.json diff --git a/containers/azure-cli/.devcontainer/ignore b/containers/azure-cli/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/azure-cli/.devcontainer/ignore +++ b/containers/azure-cli/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/azure-functions-node-8/.vscode/devContainer.json b/containers/azure-functions-node-8/.devcontainer/devcontainer.json similarity index 100% rename from containers/azure-functions-node-8/.vscode/devContainer.json rename to containers/azure-functions-node-8/.devcontainer/devcontainer.json diff --git a/containers/azure-functions-node-8/.devcontainer/ignore b/containers/azure-functions-node-8/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/azure-functions-node-8/.devcontainer/ignore +++ b/containers/azure-functions-node-8/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/azure-hdinsight-python-3/.vscode/devContainer.json b/containers/azure-hdinsight-python-3/.devcontainer/devcontainer.json similarity index 100% rename from containers/azure-hdinsight-python-3/.vscode/devContainer.json rename to containers/azure-hdinsight-python-3/.devcontainer/devcontainer.json diff --git a/containers/azure-hdinsight-python-3/.devcontainer/ignore b/containers/azure-hdinsight-python-3/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/azure-hdinsight-python-3/.devcontainer/ignore +++ b/containers/azure-hdinsight-python-3/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/azure-machine-learning-python-3/.devcontainer/ignore b/containers/azure-machine-learning-python-3/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/azure-machine-learning-python-3/.devcontainer/ignore +++ b/containers/azure-machine-learning-python-3/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/azure-machine-learning-python-3/.vscode/devContainer.json b/containers/azure-machine-learning-python-3/.vscode/devContainer.json deleted file mode 100644 index 757be27ef6..0000000000 --- a/containers/azure-machine-learning-python-3/.vscode/devContainer.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "name": "Azure Machine Learning", - "dockerFile": ".devcontainer/Dockerfile", - "extensions": [ - "ms-toolsai.vscode-ai" - ], - "runArgs": ["-v","/var/run/docker.sock:/var/run/docker.sock"] -} \ No newline at end of file diff --git a/containers/azure-terraform/.vscode/devContainer.json b/containers/azure-terraform/.devcontainer/devcontainer.json similarity index 100% rename from containers/azure-terraform/.vscode/devContainer.json rename to containers/azure-terraform/.devcontainer/devcontainer.json diff --git a/containers/azure-terraform/.devcontainer/ignore b/containers/azure-terraform/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/azure-terraform/.devcontainer/ignore +++ b/containers/azure-terraform/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/cpp/.vscode/devContainer.json b/containers/cpp/.devcontainer/devcontainer.json similarity index 100% rename from containers/cpp/.vscode/devContainer.json rename to containers/cpp/.devcontainer/devcontainer.json diff --git a/containers/cpp/.devcontainer/ignore b/containers/cpp/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/cpp/.devcontainer/ignore +++ b/containers/cpp/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/dart-web/.vscode/devContainer.json b/containers/dart-web/.devcontainer/devcontainer.json similarity index 100% rename from containers/dart-web/.vscode/devContainer.json rename to containers/dart-web/.devcontainer/devcontainer.json diff --git a/containers/dart-web/.devcontainer/ignore b/containers/dart-web/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/dart-web/.devcontainer/ignore +++ b/containers/dart-web/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/docker-existing-docker-compose/.vscode/devContainer.json b/containers/docker-existing-docker-compose/.devcontainer/devcontainer.json similarity index 100% rename from containers/docker-existing-docker-compose/.vscode/devContainer.json rename to containers/docker-existing-docker-compose/.devcontainer/devcontainer.json diff --git a/containers/docker-existing-docker-compose/.devcontainer/ignore b/containers/docker-existing-docker-compose/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/docker-existing-docker-compose/.devcontainer/ignore +++ b/containers/docker-existing-docker-compose/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/docker-existing-dockerfile/.vscode/devContainer.json b/containers/docker-existing-dockerfile/.devcontainer/devcontainer.json similarity index 100% rename from containers/docker-existing-dockerfile/.vscode/devContainer.json rename to containers/docker-existing-dockerfile/.devcontainer/devcontainer.json diff --git a/containers/docker-existing-dockerfile/.devcontainer/ignore b/containers/docker-existing-dockerfile/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/docker-existing-dockerfile/.devcontainer/ignore +++ b/containers/docker-existing-dockerfile/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/docker-in-docker-compose/.vscode/devContainer.json b/containers/docker-in-docker-compose/.devcontainer/devcontainer.json similarity index 100% rename from containers/docker-in-docker-compose/.vscode/devContainer.json rename to containers/docker-in-docker-compose/.devcontainer/devcontainer.json diff --git a/containers/docker-in-docker-compose/.devcontainer/ignore b/containers/docker-in-docker-compose/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/docker-in-docker-compose/.devcontainer/ignore +++ b/containers/docker-in-docker-compose/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/docker-in-docker/.vscode/devContainer.json b/containers/docker-in-docker/.devcontainer/devcontainer.json similarity index 100% rename from containers/docker-in-docker/.vscode/devContainer.json rename to containers/docker-in-docker/.devcontainer/devcontainer.json diff --git a/containers/docker-in-docker/.devcontainer/ignore b/containers/docker-in-docker/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/docker-in-docker/.devcontainer/ignore +++ b/containers/docker-in-docker/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/dotnetcore-2.2-fsharp/.vscode/devContainer.json b/containers/dotnetcore-2.2-fsharp/.devcontainer/devcontainer.json similarity index 100% rename from containers/dotnetcore-2.2-fsharp/.vscode/devContainer.json rename to containers/dotnetcore-2.2-fsharp/.devcontainer/devcontainer.json diff --git a/containers/dotnetcore-2.2-fsharp/.devcontainer/ignore b/containers/dotnetcore-2.2-fsharp/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/dotnetcore-2.2-fsharp/.devcontainer/ignore +++ b/containers/dotnetcore-2.2-fsharp/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/dotnetcore-2.2/.vscode/devContainer.json b/containers/dotnetcore-2.2/.devcontainer/devcontainer.json similarity index 100% rename from containers/dotnetcore-2.2/.vscode/devContainer.json rename to containers/dotnetcore-2.2/.devcontainer/devcontainer.json diff --git a/containers/dotnetcore-2.2/.devcontainer/ignore b/containers/dotnetcore-2.2/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/dotnetcore-2.2/.devcontainer/ignore +++ b/containers/dotnetcore-2.2/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/go/.vscode/devContainer.json b/containers/go/.devcontainer/devcontainer.json similarity index 100% rename from containers/go/.vscode/devContainer.json rename to containers/go/.devcontainer/devcontainer.json diff --git a/containers/go/.devcontainer/ignore b/containers/go/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/go/.devcontainer/ignore +++ b/containers/go/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/java-8-maven/.vscode/devContainer.json b/containers/java-8-maven/.devcontainer/devcontainer.json similarity index 100% rename from containers/java-8-maven/.vscode/devContainer.json rename to containers/java-8-maven/.devcontainer/devcontainer.json diff --git a/containers/java-8-maven/.devcontainer/ignore b/containers/java-8-maven/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/java-8-maven/.devcontainer/ignore +++ b/containers/java-8-maven/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/javascript-node-8-mongo/.vscode/devContainer.json b/containers/javascript-node-8-mongo/.devcontainer/devcontainer.json similarity index 100% rename from containers/javascript-node-8-mongo/.vscode/devContainer.json rename to containers/javascript-node-8-mongo/.devcontainer/devcontainer.json diff --git a/containers/javascript-node-8-mongo/.devcontainer/ignore b/containers/javascript-node-8-mongo/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/javascript-node-8-mongo/.devcontainer/ignore +++ b/containers/javascript-node-8-mongo/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/javascript-node-8/.vscode/devContainer.json b/containers/javascript-node-8/.devcontainer/devcontainer.json similarity index 100% rename from containers/javascript-node-8/.vscode/devContainer.json rename to containers/javascript-node-8/.devcontainer/devcontainer.json diff --git a/containers/javascript-node-8/.devcontainer/ignore b/containers/javascript-node-8/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/javascript-node-8/.devcontainer/ignore +++ b/containers/javascript-node-8/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/kubernetes-helm/.vscode/devContainer.json b/containers/kubernetes-helm/.devcontainer/devcontainer.json similarity index 100% rename from containers/kubernetes-helm/.vscode/devContainer.json rename to containers/kubernetes-helm/.devcontainer/devcontainer.json diff --git a/containers/kubernetes-helm/.devcontainer/ignore b/containers/kubernetes-helm/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/kubernetes-helm/.devcontainer/ignore +++ b/containers/kubernetes-helm/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/latex/.devcontainer/ignore b/containers/latex/.devcontainer/ignore deleted file mode 100644 index 32ec647693..0000000000 --- a/containers/latex/.devcontainer/ignore +++ /dev/null @@ -1,5 +0,0 @@ -README.md -test-project -.vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/latex/.vscode/devContainer.json b/containers/latex/.vscode/devContainer.json deleted file mode 100644 index 1acc444661..0000000000 --- a/containers/latex/.vscode/devContainer.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "name": "LaTeX", - "image": "tianon/latex", - "extensions": [ - "James-Yu.latex-workshop" - ] -} \ No newline at end of file diff --git a/containers/latex/README.md b/containers/latex/README.md deleted file mode 100644 index c82006fba4..0000000000 --- a/containers/latex/README.md +++ /dev/null @@ -1,5 +0,0 @@ -# LaTeX container - -To test, grab a sample .tex file from somewhere and place it in this folder. - -For example, you can find samples and templates [here](https://www.latextemplates.com) and [here](https://services.math.duke.edu/computing/tex/templates.html). \ No newline at end of file diff --git a/containers/markdown/.vscode/devContainer.json b/containers/markdown/.devcontainer/devcontainer.json similarity index 100% rename from containers/markdown/.vscode/devContainer.json rename to containers/markdown/.devcontainer/devcontainer.json diff --git a/containers/markdown/.devcontainer/ignore b/containers/markdown/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/markdown/.devcontainer/ignore +++ b/containers/markdown/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/php-7/.vscode/devContainer.json b/containers/php-7/.devcontainer/devcontainer.json similarity index 100% rename from containers/php-7/.vscode/devContainer.json rename to containers/php-7/.devcontainer/devcontainer.json diff --git a/containers/php-7/.devcontainer/ignore b/containers/php-7/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/php-7/.devcontainer/ignore +++ b/containers/php-7/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/plantuml/.vscode/devContainer.json b/containers/plantuml/.devcontainer/devcontainer.json similarity index 100% rename from containers/plantuml/.vscode/devContainer.json rename to containers/plantuml/.devcontainer/devcontainer.json diff --git a/containers/plantuml/.devcontainer/ignore b/containers/plantuml/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/plantuml/.devcontainer/ignore +++ b/containers/plantuml/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/powershell/.vscode/devContainer.json b/containers/powershell/.devcontainer/devcontainer.json similarity index 100% rename from containers/powershell/.vscode/devContainer.json rename to containers/powershell/.devcontainer/devcontainer.json diff --git a/containers/powershell/.devcontainer/ignore b/containers/powershell/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/powershell/.devcontainer/ignore +++ b/containers/powershell/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/python-2/.vscode/devContainer.json b/containers/python-2/.devcontainer/devcontainer.json similarity index 100% rename from containers/python-2/.vscode/devContainer.json rename to containers/python-2/.devcontainer/devcontainer.json diff --git a/containers/python-2/.devcontainer/ignore b/containers/python-2/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/python-2/.devcontainer/ignore +++ b/containers/python-2/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/python-3-django/.vscode/devContainer.json b/containers/python-3-django/.devcontainer/devcontainer.json similarity index 100% rename from containers/python-3-django/.vscode/devContainer.json rename to containers/python-3-django/.devcontainer/devcontainer.json diff --git a/containers/python-3-django/.devcontainer/ignore b/containers/python-3-django/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/python-3-django/.devcontainer/ignore +++ b/containers/python-3-django/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/python-3-flask-redis/.vscode/devContainer.json b/containers/python-3-flask-redis/.devcontainer/devcontainer.json similarity index 100% rename from containers/python-3-flask-redis/.vscode/devContainer.json rename to containers/python-3-flask-redis/.devcontainer/devcontainer.json diff --git a/containers/python-3-flask-redis/.devcontainer/ignore b/containers/python-3-flask-redis/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/python-3-flask-redis/.devcontainer/ignore +++ b/containers/python-3-flask-redis/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/python-3-jupyter-pyspark/.vscode/devContainer.json b/containers/python-3-jupyter-pyspark/.devcontainer/devcontainer.json similarity index 100% rename from containers/python-3-jupyter-pyspark/.vscode/devContainer.json rename to containers/python-3-jupyter-pyspark/.devcontainer/devcontainer.json diff --git a/containers/python-3-jupyter-pyspark/.devcontainer/ignore b/containers/python-3-jupyter-pyspark/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/python-3-jupyter-pyspark/.devcontainer/ignore +++ b/containers/python-3-jupyter-pyspark/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/python-3/.vscode/devContainer.json b/containers/python-3/.devcontainer/devcontainer.json similarity index 100% rename from containers/python-3/.vscode/devContainer.json rename to containers/python-3/.devcontainer/devcontainer.json diff --git a/containers/python-3/.devcontainer/ignore b/containers/python-3/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/python-3/.devcontainer/ignore +++ b/containers/python-3/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/ruby-2/.vscode/devContainer.json b/containers/ruby-2/.devcontainer/devcontainer.json similarity index 100% rename from containers/ruby-2/.vscode/devContainer.json rename to containers/ruby-2/.devcontainer/devcontainer.json diff --git a/containers/ruby-2/.devcontainer/ignore b/containers/ruby-2/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/ruby-2/.devcontainer/ignore +++ b/containers/ruby-2/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/rust/.vscode/devContainer.json b/containers/rust/.devcontainer/devcontainer.json similarity index 100% rename from containers/rust/.vscode/devContainer.json rename to containers/rust/.devcontainer/devcontainer.json diff --git a/containers/rust/.devcontainer/ignore b/containers/rust/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/rust/.devcontainer/ignore +++ b/containers/rust/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json diff --git a/containers/swift-4/.vscode/devContainer.json b/containers/swift-4/.devcontainer/devcontainer.json similarity index 100% rename from containers/swift-4/.vscode/devContainer.json rename to containers/swift-4/.devcontainer/devcontainer.json diff --git a/containers/swift-4/.devcontainer/ignore b/containers/swift-4/.devcontainer/ignore index 7f19386cd9..456152430f 100644 --- a/containers/swift-4/.devcontainer/ignore +++ b/containers/swift-4/.devcontainer/ignore @@ -1,6 +1,3 @@ -../README.md -../test-project -../.vscode/launch.json -../.vscode/launch.test.json -../.vscode/settings.json -../.vscode/tasks.json +README.md +test-project +.vscode diff --git a/containers/typescript-node-8/.vscode/devContainer.json b/containers/typescript-node-8/.devcontainer/devcontainer.json similarity index 100% rename from containers/typescript-node-8/.vscode/devContainer.json rename to containers/typescript-node-8/.devcontainer/devcontainer.json diff --git a/containers/typescript-node-8/.devcontainer/ignore b/containers/typescript-node-8/.devcontainer/ignore index 32ec647693..456152430f 100644 --- a/containers/typescript-node-8/.devcontainer/ignore +++ b/containers/typescript-node-8/.devcontainer/ignore @@ -1,5 +1,3 @@ README.md test-project .vscode -!.vscode/devContainer.json -!.vscode/devcontainer.json From a08f9cae338d069fe2b16dc42ffe441f420c3329 Mon Sep 17 00:00:00 2001 From: Chuck Lantz Date: Wed, 3 Apr 2019 15:39:23 -0700 Subject: [PATCH 2/7] Update README.md --- README.md | 50 ++++++++++++++++++++++---------------------------- 1 file changed, 22 insertions(+), 28 deletions(-) diff --git a/README.md b/README.md index fc2ff96b04..701fd9bf3b 100644 --- a/README.md +++ b/README.md @@ -26,48 +26,42 @@ You can either: - Manually copy the contents of one of the `containers` sub-folders into your project. Copy the `.devcontainer` folder into your project and you should be ready to go! -### Can I just reuse an existing Docker configuration? +## Adding a definition to an existing public or private repo -Absolutely! If you want to use an existing Dockerfile as a starting point, run **Remote-Containers: Create Container Configuration File...** from the command pallette (Cmd/Ctrl+Shift+P). You'll be prompted to select a Dockerfile or you can opt to use a base image instead. +You can easily share a customized dev container definition for your project by simply adding files like `.devcontainer/devcontainer.json` to source control. By including these files in your repository, anyone that opens a local copy of your repo in VS Code will be automatically asked if they want reopen the folder in a container instead if the [Remote Development](https://aka.ms/vscode-remote/download/extension) extension installed. -#### About `.devcontainer/devcontainer.json` +Beyond the advantages of having your team use a consistent environment and tool-chain, doing this can make it easier for new contributors or team members to get productive quickly. First-time contributors will require less guidance and are less likely to either submit issues or contribute code with issues that are related to environment setup. -The intent of `devcontainer.json` is conceptually similar to VS Code's `launch.json` for debugging, but designed to launch (or attach to) your development container instead. At its simplest, all you need to do is add a `.devcontainer/devcontainer.json` file to your project and reference an image, `Dockerfile`, or `docker-compose.yml`. +## Contents -Since you are here, check out the [existing Dockerfile](containers/docker-existing-dockerfile) and [existing Docker Compose](containers/docker-existing-docker-compose) definitions for details, but here's the a quick tour of the basic properties. If you have a `Dockerfile`, set these properties: +- `containers` - Dev container definition folders. +- `container-templates` - Templates for creating your own container definitions in your project or for contributing back to this repository. -```json -{ - "name": "[Optional] Your project name here", - "dockerFile": "Dockerfile" -} -``` +## Common Questions -For Docker Compose, you can [attach to an already running container](https://aka.ms/vscode-remote/containers/attach) or configure `.devcontainer/devcontainer.json` with these properties: +#### Can I just reuse an existing container image or Docker configuration? -```json -{ - "name": "[Optional] Your project name here", - "dockerComposeFile": "docker-compose.yml", - "service": "the-name-of-the-service-you-want-to-work-with-in-vscode", - "volume": "name-of-volume-where-source-code-is-located" -} -``` +Absolutely! If you want to use an existing Dockerfile as a starting point, run **Remote-Containers: Create Container Configuration File...** from the command pallette (Cmd/Ctrl+Shift+P). You'll be prompted to select a Dockerfile or you can opt to use a base image instead and customize from there. -Note that, if you only have a single deployment / non-development focused `docker-compose.yml`, you may want to [extend your Docker Compose file](https://aka.ms/vscode-remote/docker/docker-compose/development-version) to override or supplement what happens when your containers are started. +You can also check out the [existing Dockerfile](containers/docker-existing-dockerfile) and [existing Docker Compose](containers/docker-existing-docker-compose) definitions for an example. You can also [attach to an already running container](https://aka.ms/vscode-remote/containers/attach) if you'd prefer. -The other definitions in the `containers` folder will provide examples of how to cover new scenarios you may encounter along the way. For example, you may want to [alter your configuration](https://aka.ms/vscode-remote/containers/folder-setup) to install additional tools like Git in the container, automatically install extensions, expose additional ports, or set runtime arguments. In other cases, you may just want to [attach to an already running container](https://aka.ms/vscode-remote/containers/attach). +##### What is the goal of `devcontainer.json`? -## Adding a definition to an existing public or private repo +The intent of `devcontainer.json` is conceptually similar to VS Code's `launch.json` for debugging, but designed to launch (or attach to) your development container instead. At its simplest, all you need to do is add a `.devcontainer/devcontainer.json` file to your project and reference an image, `Dockerfile`, or `docker-compose.yml` and a few properties. -You can easily share a customized dev container definition for your project by simply adding files like `.devcontainer/devcontainer.json` to source control. By including these files in your repository, anyone that opens a local copy of your repo in VS Code will be automatically asked if they want reopen the folder in a container instead if the [Remote Development](https://aka.ms/vscode-remote/download/extension) extension installed. +Check out the `container-templates` folder for simple examples and the definitions in the `containers` folder illustrate ways to handle a number of different scenarios. From there, you can [alter your configuration](https://aka.ms/vscode-remote/containers/folder-setup) to install additional tools like Git in the container, automatically install extensions, expose additional ports, set runtime arguments, and more. -Beyond the advantages of having your team use a consistent environment and tool-chain, doing this can make it easier for new contributors or team members to get productive quickly. First-time contributors will require less guidance and are less likely to either submit issues or contribute code with issues that are related to environment setup. +#### Are development containers intended to define how an application is deployed? -## Contents +No. A development container is an environment that you can use to develop your application even before you are ready to build or deploy. The "dev container definitions" found in the [vscode-dev-containers repo](https://aka.ms/vscode-dev-containers) are intended to help jump start this process by including a set of well-known container build or deployment files and a `devcontainer.json` file. `devcontainer.json` is not intended to provide a home for tooling and edit-time related settings and a pointer to the image (or files that define the image) that should be used for the development container. -- `containers` - Dev container definition folders. -- `container-templates` - Templates for creating your own container definitions in your project or for contributing back to this repository. +Support for [attaching to a running container](#attaching-to-running-containers) can be used to interact with deployment focused containers or for other container build or deployment workflows. + +#### Are development containers intended to define how an application is built? Like Buildpacks? + +No. The [Buildpack](https://buildpacks.io/) concept focuses on taking source code and generating deployable container images through a series of defined steps. A dev container is an environment you can use to develop your application even before you are ready to build. They are therefore complementary concepts. The `devcontainer.json` file is not intended to define how your application should be built, but rather provides a home for tooling and edit-time related settings and a pointer to an image or image definition files. Today it supports pointing to an existing image (which could be generated by a Buildpack), a Dockerfile, or one or more `docker-compose.yml` files, and more may be added over time. In all cases, support for [attaching to a running container](#attaching-to-running-containers) can be used to work with alternate container build or deployment workflows. + +Similarly, the "dev container definitions" found in the [vscode-dev-containers repo](https://aka.ms/vscode-dev-containers) help jump start the process of creating a dev container when you do not have an existing image, `Dockerfile`, or `docker-compose.yml`. These can also act as samples if you do have existing container files. They are not intended to define how an application should be built. ## Contributing & Feedback From 3f6afc6f191ab78309851cc8749076ac9d382831 Mon Sep 17 00:00:00 2001 From: Chuck Lantz Date: Wed, 3 Apr 2019 15:42:40 -0700 Subject: [PATCH 3/7] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 701fd9bf3b..d78b922184 100644 --- a/README.md +++ b/README.md @@ -53,7 +53,7 @@ Check out the `container-templates` folder for simple examples and the definitio #### Are development containers intended to define how an application is deployed? -No. A development container is an environment that you can use to develop your application even before you are ready to build or deploy. The "dev container definitions" found in the [vscode-dev-containers repo](https://aka.ms/vscode-dev-containers) are intended to help jump start this process by including a set of well-known container build or deployment files and a `devcontainer.json` file. `devcontainer.json` is not intended to provide a home for tooling and edit-time related settings and a pointer to the image (or files that define the image) that should be used for the development container. +No. A development container is an environment that you can use to develop your application even before you are ready to build or deploy. The "dev container definitions" found in the [vscode-dev-containers repo](https://aka.ms/vscode-dev-containers) are intended to help jump start this process by including a set of well-known container build or deployment files and a `devcontainer.json` file. This file provides a home for tooling and edit-time related settings and a pointer to the image (or files that define the image) that should be used for the development container. Support for [attaching to a running container](#attaching-to-running-containers) can be used to interact with deployment focused containers or for other container build or deployment workflows. From 0502412e68f2f68975af81038266f5ae14181250 Mon Sep 17 00:00:00 2001 From: Chuck Lantz Date: Wed, 3 Apr 2019 15:45:18 -0700 Subject: [PATCH 4/7] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index d78b922184..5c8494e27b 100644 --- a/README.md +++ b/README.md @@ -49,7 +49,7 @@ You can also check out the [existing Dockerfile](containers/docker-existing-dock The intent of `devcontainer.json` is conceptually similar to VS Code's `launch.json` for debugging, but designed to launch (or attach to) your development container instead. At its simplest, all you need to do is add a `.devcontainer/devcontainer.json` file to your project and reference an image, `Dockerfile`, or `docker-compose.yml` and a few properties. -Check out the `container-templates` folder for simple examples and the definitions in the `containers` folder illustrate ways to handle a number of different scenarios. From there, you can [alter your configuration](https://aka.ms/vscode-remote/containers/folder-setup) to install additional tools like Git in the container, automatically install extensions, expose additional ports, set runtime arguments, and more. +Check out the `container-templates` folder for simple examples. The definitions in the `containers` folder can be used as-is or as samples for how to modify your existing config to support different scenarios. From there, you can [alter your configuration](https://aka.ms/vscode-remote/containers/folder-setup) to install additional tools like Git in the container, automatically install other extensions, expose additional ports, set runtime arguments, and more. #### Are development containers intended to define how an application is deployed? From 84d7001d2180784d38c930375befd959d5db2fac Mon Sep 17 00:00:00 2001 From: Chuck Lantz Date: Wed, 3 Apr 2019 16:20:38 -0700 Subject: [PATCH 5/7] Update README.md --- README.md | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 5c8494e27b..27c1e9b159 100644 --- a/README.md +++ b/README.md @@ -51,17 +51,15 @@ The intent of `devcontainer.json` is conceptually similar to VS Code's `launch.j Check out the `container-templates` folder for simple examples. The definitions in the `containers` folder can be used as-is or as samples for how to modify your existing config to support different scenarios. From there, you can [alter your configuration](https://aka.ms/vscode-remote/containers/folder-setup) to install additional tools like Git in the container, automatically install other extensions, expose additional ports, set runtime arguments, and more. -#### Are development containers intended to define how an application is deployed? +### Are development containers intended to define how an application is deployed? -No. A development container is an environment that you can use to develop your application even before you are ready to build or deploy. The "dev container definitions" found in the [vscode-dev-containers repo](https://aka.ms/vscode-dev-containers) are intended to help jump start this process by including a set of well-known container build or deployment files and a `devcontainer.json` file. This file provides a home for tooling and edit-time related settings and a pointer to the image (or files that define the image) that should be used for the development container. +No. A development container is an environment that you can use to develop your application even before you are ready to build or deploy. While deployment and development containers may resemble one another, you often will not include tools in a deployment image that you will want during development. The set of "dev container definitions" found in the [vscode-dev-containers repo](https://aka.ms/vscode-dev-containers) are intended to help jump start the process of creating a development container by including a set of well-known container build or deployment files and a `devcontainer.json` file. This file provides a home for tooling and edit-time related settings and a pointer to the image (or files that define the image) that should be used for the development container. However, their use is entirely optional, and you can [attach to a running container](https://aka.ms/vscode-remote/attach) in other container-based workflows and scenarios. -Support for [attaching to a running container](#attaching-to-running-containers) can be used to interact with deployment focused containers or for other container build or deployment workflows. +### Are development containers intended to define how an application is built? Like Buildpacks? -#### Are development containers intended to define how an application is built? Like Buildpacks? +No. The [Buildpack](https://buildpacks.io/) concept focuses on taking source code and generating deployable container images through a series of defined steps. A dev container is an environment you can use to develop your application even before you are ready to build. They are therefore complementary concepts. The `devcontainer.json` file is not intended to define how your application should be built, but rather provides a home for tooling and edit-time related settings and a pointer to an image or image definition files. Today it supports pointing to an existing image (which could be generated by a Buildpack), a Dockerfile, or one or more `docker-compose.yml` files, but more will be added as the community has interest. You can also opt to [attach to a running container](https://aka.ms/vscode-remote/attach) if you prefer to use an alternate container build or deployment workflow. -No. The [Buildpack](https://buildpacks.io/) concept focuses on taking source code and generating deployable container images through a series of defined steps. A dev container is an environment you can use to develop your application even before you are ready to build. They are therefore complementary concepts. The `devcontainer.json` file is not intended to define how your application should be built, but rather provides a home for tooling and edit-time related settings and a pointer to an image or image definition files. Today it supports pointing to an existing image (which could be generated by a Buildpack), a Dockerfile, or one or more `docker-compose.yml` files, and more may be added over time. In all cases, support for [attaching to a running container](#attaching-to-running-containers) can be used to work with alternate container build or deployment workflows. - -Similarly, the "dev container definitions" found in the [vscode-dev-containers repo](https://aka.ms/vscode-dev-containers) help jump start the process of creating a dev container when you do not have an existing image, `Dockerfile`, or `docker-compose.yml`. These can also act as samples if you do have existing container files. They are not intended to define how an application should be built. +Similarly, the "dev container definitions" found in the [vscode-dev-containers repo](https://aka.ms/vscode-dev-containers) can help jump start the process of creating a dev container when you do not have an existing image, `Dockerfile`, or `docker-compose.yml`. These can also act as samples if you do have existing container files. However, they are not intended to define how an application should be built. ## Contributing & Feedback From b9cecd0600e279fed82e2ace11ed2d9d61d03d85 Mon Sep 17 00:00:00 2001 From: Chuck Lantz Date: Thu, 4 Apr 2019 13:55:54 -0700 Subject: [PATCH 6/7] Small edits --- README.md | 6 +++--- containers/rust/.devcontainer/ignore | 3 +++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 27c1e9b159..7a9e770a0c 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ The Containers extension in the [Visual Studio Code Remote Development](https:// **[Learn more about the Visual Studio Code Remote - Containers extension](https://aka.ms/vscode-remote/containers)**. -This repository contains a set of **dev container definitions** made up of files like `devcontainer.json` to help get you up and running in a containerized environment. These definitions describe the needed container image, any runtime arguments for starting the container, and any VS Code extensions that should be installed into it. +This repository contains a set of **dev container definitions** made up of files like `devcontainer.json` to help get you up and running in a containerized environment. These definitions describe the needed container image, any runtime arguments for starting the container, and any VS Code extensions that should be installed into it. They're can be useful to help you get started or as samples for how to adapt your own configuration to different situations. ## Trying a definition @@ -14,9 +14,9 @@ This repository contains a set of **dev container definitions** made up of files 2. Check out the README to see if there are any manual steps 3. Clone this repository or copy the contents of the folder to your machine 4. Run the **Remote: Open Folder in Container...** command in VS Code -5. Select the definition folder in the "open" dialog +5. Select the root of the definition folder in the "open" dialog (**not** the `test-project` folder if present) -Many definitions include a `test-project` that you can use to see the dev container in action. Note that if you open this folder locally instead, you'll be prompted to reopen it in a container as well. You can also use the **Remote: Reopen Folder in Container** command at any time. +Many definitions include a `test-project` with a sample and/or launch settings in the `.vscode` folder that you can use to see the dev container in action. If you open the folder locally instead, you'll be prompted to reopen it in a container but uou can also use the **Remote: Reopen Folder in Container** command at any time. ## Using a definition diff --git a/containers/rust/.devcontainer/ignore b/containers/rust/.devcontainer/ignore index 456152430f..0d770672d8 100644 --- a/containers/rust/.devcontainer/ignore +++ b/containers/rust/.devcontainer/ignore @@ -1,3 +1,6 @@ README.md test-project .vscode +src +Cargo.lock +Cargo.toml From 0cef84c24c881beb6f8308b883e6e98e1f092d25 Mon Sep 17 00:00:00 2001 From: Chuck Lantz Date: Fri, 5 Apr 2019 13:29:29 -0700 Subject: [PATCH 7/7] volume => workspaceFolder --- {.vscode => .devcontainer}/Dockerfile | 0 .../devcontainer.json | 2 +- README.md | 4 ++-- .../.devcontainer/devcontainer.json | 17 ++++++++++------- .../.devcontainer/devcontainer.json | 14 +++++++++----- .../.devcontainer/devcontainer.json | 2 +- .../.devcontainer/devcontainer.json | 2 +- .../.devcontainer/docker-compose.yml | 2 +- .../.devcontainer/devcontainer.json | 2 +- .../.devcontainer/devcontainer.json | 2 +- .../.devcontainer/docker-compose.yml | 2 +- 11 files changed, 28 insertions(+), 21 deletions(-) rename {.vscode => .devcontainer}/Dockerfile (100%) rename .vscode/devContainer.json => .devcontainer/devcontainer.json (89%) diff --git a/.vscode/Dockerfile b/.devcontainer/Dockerfile similarity index 100% rename from .vscode/Dockerfile rename to .devcontainer/Dockerfile diff --git a/.vscode/devContainer.json b/.devcontainer/devcontainer.json similarity index 89% rename from .vscode/devContainer.json rename to .devcontainer/devcontainer.json index 07b72c6824..5da1c458b4 100644 --- a/.vscode/devContainer.json +++ b/.devcontainer/devcontainer.json @@ -1,6 +1,6 @@ { "name": "Dev Container Editing", - "dockerFile": ".vscode/Dockerfile", + "dockerFile": ".devcontainer/Dockerfile", "extensions": [ "yzhang.markdown-all-in-one", "streetsidesoftware.code-spell-checker", diff --git a/README.md b/README.md index 7a9e770a0c..fae00ea1b6 100644 --- a/README.md +++ b/README.md @@ -22,10 +22,10 @@ Many definitions include a `test-project` with a sample and/or launch settings i You can either: -- Run **Remote: Create Container Configuration File...** command in VS Code and pick a definition. The appropriate files will then be added to your project. - - Manually copy the contents of one of the `containers` sub-folders into your project. Copy the `.devcontainer` folder into your project and you should be ready to go! +- Run **Remote: Create Container Configuration File...** command in VS Code and pick a definition. The appropriate files will then be added to your project. + ## Adding a definition to an existing public or private repo You can easily share a customized dev container definition for your project by simply adding files like `.devcontainer/devcontainer.json` to source control. By including these files in your repository, anyone that opens a local copy of your repo in VS Code will be automatically asked if they want reopen the folder in a container instead if the [Remote Development](https://aka.ms/vscode-remote/download/extension) extension installed. diff --git a/containers/docker-existing-docker-compose/.devcontainer/devcontainer.json b/containers/docker-existing-docker-compose/.devcontainer/devcontainer.json index d20c9f154f..d6b13aea96 100644 --- a/containers/docker-existing-docker-compose/.devcontainer/devcontainer.json +++ b/containers/docker-existing-docker-compose/.devcontainer/devcontainer.json @@ -1,18 +1,21 @@ { "name": "Existing Docker Compose", - "// Update this list if you have more compose files or use different names. The": "", - "// .devcontainer/docker-compose.yml file contains any overrides you need/want to make.":"", + // Update the dockerComposeFile list if you have more compose files or use different names. + // The .devcontainer/docker-compose.yml file contains any overrides you need/want to make. + "dockerComposeFile": [ "docker-compose.yml", ".devcontainer/docker-compose.yml" ], - "// The service property is the name of the service for the container that VS Code should": "", - "// use. Update this value and .devcontainer/docker-compose.yml to the real service name.":"", + // The "service" property is the name of the service for the container that VS Code should + // use. Update this value and .devcontainer/docker-compose.yml to the real service name. + "service": "your-service-name-here", - "// The volume property is the path VS Code should open by default when connected to the service.": "", - "// This is typically a file mount in .devcontainer/docker-compose.yml":"", - "volume": "workspace" + // The optonal "workspaceFolder" property is the path VS Code should open by default when + // connected. This is typically a file mount in .devcontainer/docker-compose.yml + + "workspaceFolder": "/workspace" } diff --git a/containers/docker-existing-dockerfile/.devcontainer/devcontainer.json b/containers/docker-existing-dockerfile/.devcontainer/devcontainer.json index b3f7fb4539..b39cfff8f5 100644 --- a/containers/docker-existing-dockerfile/.devcontainer/devcontainer.json +++ b/containers/docker-existing-dockerfile/.devcontainer/devcontainer.json @@ -1,14 +1,18 @@ { "name": "Existing Dockerfile", - "// Update the dockerFile property if you aren't using the standard 'Dockerfile' filename":"", + // Update the "dockerFile" property if you aren't using the standard 'Dockerfile' filename. + "dockerFile": "Dockerfile", - "// Use appPort to list ports you want to expose that aren't already exposed in your Dockerfile":"", + // Use the optional "appPort" property to expose ports not already in your Dockerfile + "appPort": [], - "// If you install the Docker CE CLI in your container, this runArgs list lets you interact with your host":"", - "// Docker service from inside the container. See the docker-in-docker and docker-in-docker-compose": "", - "// definitions for details.":"", + // The optional "runArgs" property can be used to specify Docker CLI arguments to use when the container. + // is started. If you install the Docker CE CLI in your container, the runArgs list below will lets you interact + // with your host's Docker service from inside the container. See the docker-in-docker and docker-in-docker-compose + // definitions for details. + "runArgs": ["-v","/var/run/docker.sock:/var/run/docker.sock"] } diff --git a/containers/docker-in-docker-compose/.devcontainer/devcontainer.json b/containers/docker-in-docker-compose/.devcontainer/devcontainer.json index c863fe9a65..f0ff7ac382 100644 --- a/containers/docker-in-docker-compose/.devcontainer/devcontainer.json +++ b/containers/docker-in-docker-compose/.devcontainer/devcontainer.json @@ -2,7 +2,7 @@ "name": "Docker-in-Docker", "dockerComposeFile": ".devcontainer/docker-compose.yml", "service": "docker-in-docker", - "volume": "workspace", + "workspaceFolder": "/workspace", "extensions": [ "peterjausovec.vscode-docker" ] diff --git a/containers/javascript-node-8-mongo/.devcontainer/devcontainer.json b/containers/javascript-node-8-mongo/.devcontainer/devcontainer.json index c815fd59f7..b1c22f3121 100644 --- a/containers/javascript-node-8-mongo/.devcontainer/devcontainer.json +++ b/containers/javascript-node-8-mongo/.devcontainer/devcontainer.json @@ -2,7 +2,7 @@ "name": "Node.js & Mongo DB", "dockerComposeFile": ".devcontainer/docker-compose.yml", "service": "web", - "volume": "app", + "workspaceFolder": "/workspace", "extensions": [ "dbaeumer.vscode-eslint" ] diff --git a/containers/javascript-node-8-mongo/.devcontainer/docker-compose.yml b/containers/javascript-node-8-mongo/.devcontainer/docker-compose.yml index 7bf6f428ed..c2d8613882 100644 --- a/containers/javascript-node-8-mongo/.devcontainer/docker-compose.yml +++ b/containers/javascript-node-8-mongo/.devcontainer/docker-compose.yml @@ -10,7 +10,7 @@ services: context: . dockerfile: Dockerfile volumes: - - ..:/app + - ..:/workspace ports: - "3000:3000" command: sleep infinity diff --git a/containers/python-3-flask-redis/.devcontainer/devcontainer.json b/containers/python-3-flask-redis/.devcontainer/devcontainer.json index 0355ba00f3..c5b4ab1f76 100644 --- a/containers/python-3-flask-redis/.devcontainer/devcontainer.json +++ b/containers/python-3-flask-redis/.devcontainer/devcontainer.json @@ -2,7 +2,7 @@ "name": "Python & Redis", "dockerComposeFile": ".devcontainer/docker-compose.yml", "service": "web", - "volume": "workspace", + "workspaceFolder": "/workspace", "extensions": [ "ms-python.python", "LittleFoxTeam.vscode-python-test-adapter" diff --git a/containers/python-3-jupyter-pyspark/.devcontainer/devcontainer.json b/containers/python-3-jupyter-pyspark/.devcontainer/devcontainer.json index b1218ebec5..cd54f86f73 100644 --- a/containers/python-3-jupyter-pyspark/.devcontainer/devcontainer.json +++ b/containers/python-3-jupyter-pyspark/.devcontainer/devcontainer.json @@ -2,7 +2,7 @@ "name": "Jupyter PySpark", "dockerComposeFile": ".devcontainer/docker-compose.yml", "service": "jupyter", - "volume": "notebook", + "workspaceFolder": "/notebooks", "extensions": [ "ms-python.python" ] diff --git a/containers/python-3-jupyter-pyspark/.devcontainer/docker-compose.yml b/containers/python-3-jupyter-pyspark/.devcontainer/docker-compose.yml index d14c0047a5..048127d8e8 100644 --- a/containers/python-3-jupyter-pyspark/.devcontainer/docker-compose.yml +++ b/containers/python-3-jupyter-pyspark/.devcontainer/docker-compose.yml @@ -15,5 +15,5 @@ services: ports: - "8888:8888" volumes: - - ..:/notebook + - ..:/notebooks