-
Notifications
You must be signed in to change notification settings - Fork 150
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
32 additions
and
584 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,43 +1,40 @@ | ||
// For format details, see https://aka.ms/devcontainer.json. For config options, see the | ||
// README at: https://github.com/devcontainers/templates/tree/main/src/java | ||
{ | ||
"name": "Java PLUS Docker from Docker", | ||
"build": { | ||
"dockerfile": "Dockerfile", | ||
"args": { | ||
// Update the VARIANT arg to pick a Java version: 11, 14 | ||
"VARIANT": "17", | ||
// Options | ||
"INSTALL_MAVEN": "true", | ||
"INSTALL_GRADLE": "false", | ||
"INSTALL_NODE": "false", | ||
"NODE_VERSION": "lts/*" | ||
"name": "Java", | ||
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile | ||
"image": "mcr.microsoft.com/devcontainers/java:1-21", | ||
|
||
"features": { | ||
"ghcr.io/devcontainers/features/java:1": { | ||
"version": "none", | ||
"installMaven": "true", | ||
"mavenVersion": "3.9.9", | ||
"installGradle": "false" | ||
}, | ||
"ghcr.io/devcontainers/features/docker-in-docker:2": { | ||
"version": "latest", | ||
"moby": true | ||
} | ||
}, | ||
"runArgs": [ | ||
"--init" | ||
], | ||
"mounts": [ | ||
"source=/var/run/docker.sock,target=/var/run/docker-host.sock,type=bind" | ||
], | ||
// Use this environment variable if you need to bind mount your local source code into a new container. | ||
"remoteEnv": { | ||
"LOCAL_WORKSPACE_FOLDER": "${localWorkspaceFolder}" | ||
}, | ||
// Set *default* container specific settings.json values on container create. | ||
"settings": { | ||
"java.home": "/docker-java-home", | ||
"maven.executable.path": "/usr/local/sdkman/candidates/maven/current/bin/mvn" | ||
|
||
// Configure tool-specific properties. | ||
"customizations": { | ||
// Configure properties specific to VS Code. | ||
"vscode": { | ||
"settings": {}, | ||
"extensions": [ | ||
"streetsidesoftware.code-spell-checker" | ||
] | ||
} | ||
}, | ||
// Add the IDs of extensions you want installed when the container is created. | ||
"extensions": [ | ||
"ms-azuretools.vscode-docker", | ||
"vscjava.vscode-java-pack" | ||
] | ||
|
||
// Use 'forwardPorts' to make a list of ports inside the container available locally. | ||
// "forwardPorts": [], | ||
|
||
// Use 'postCreateCommand' to run commands after the container is created. | ||
// "postCreateCommand": "docker --version", | ||
// Uncomment the next two lines to connect as a non-root user. See https://aka.ms/vscode-remote/containers/non-root. | ||
, | ||
"overrideCommand": false, | ||
"remoteUser": "vscode" | ||
"postCreateCommand": "mvn --version" | ||
|
||
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root. | ||
// "remoteUser": "root" | ||
} |
Oops, something went wrong.