Skip to content

Commit ad58baf

Browse files
committed
add devcontainer
1 parent dd82500 commit ad58baf

File tree

1 file changed

+37
-0
lines changed

1 file changed

+37
-0
lines changed

.devcontainer/java/devcontainer.json

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
2+
// README at: https://github.com/devcontainers/templates/tree/main/src/java
3+
{
4+
"name": "Java",
5+
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
6+
"image": "mcr.microsoft.com/devcontainers/java:1-21",
7+
8+
"features": {
9+
"ghcr.io/devcontainers/features/java:1": {
10+
"version": "none",
11+
"installMaven": "true",
12+
"mavenVersion": "3.8.6",
13+
"installGradle": "false"
14+
}
15+
},
16+
17+
// Configure tool-specific properties.
18+
"customizations": {
19+
// Configure properties specific to VS Code.
20+
"vscode": {
21+
"settings": {},
22+
"extensions": [
23+
"streetsidesoftware.code-spell-checker",
24+
"vscjava.vscode-java-pack"
25+
]
26+
}
27+
}
28+
29+
// Use 'forwardPorts' to make a list of ports inside the container available locally.
30+
// "forwardPorts": [],
31+
32+
// Use 'postCreateCommand' to run commands after the container is created.
33+
// "postCreateCommand": "java -version",
34+
35+
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
36+
// "remoteUser": "root"
37+
}

0 commit comments

Comments
 (0)