testcontainers-java
52 строки · 1.8 Кб
1// For format details, see https://aka.ms/devcontainer.json. For config options, see the README at:
2// https://github.com/microsoft/vscode-dev-containers/tree/v0.241.1/containers/java-8
3{
4"name": "Java 8",
5"image": "mcr.microsoft.com/devcontainers/java:1-8-bullseye",
6
7// Configure tool-specific properties.
8"customizations": {
9// Configure properties specific to VS Code.
10"vscode": {
11// Set *default* container specific settings.json values on container create.
12"settings": {
13"java.import.gradle.java.home": "/usr/local/sdkman/candidates/java/current",
14"java.configuration.runtimes": [{
15"default": true,
16"name": "JavaSE-1.8",
17"path": "/usr/local/sdkman/candidates/java/current"
18}]
19},
20
21// Add the IDs of extensions you want installed when the container is created.
22"extensions": [
23"vscjava.vscode-java-pack"
24]
25}
26},
27
28// Use 'forwardPorts' to make a list of ports inside the container available locally.
29// "forwardPorts": [],
30
31// Use 'postCreateCommand' to run commands after the container is created.
32// "postCreateCommand": "java -version",
33
34// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
35"remoteUser": "vscode",
36"features": {
37"ghcr.io/devcontainers/features/git:1": {},
38"ghcr.io/devcontainers/features/github-cli:1": {},
39"ghcr.io/meaningful-ooo/devcontainer-features/homebrew:2": {},
40"ghcr.io/devcontainers/features/java:1": {
41"version": "none",
42"installMaven": "false",
43"installGradle": "false"
44},
45"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {},
46"ghcr.io/devcontainers/features/node:1": {},
47"ghcr.io/devcontainers/features/sshd:1": {
48"version": "latest"
49}
50},
51"postStartCommand": ["./gradlew", "compileJava"]
52}
53