Skip to content

Commit 81bdf0b

Browse files
author
FAGGIANELLI Luca
committed
add devcontainer config
1 parent 8b28c0f commit 81bdf0b

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

.devcontainer/devcontainer.json

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
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/javascript-node
3+
{
4+
"name": "Node.js",
5+
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
6+
"image": "mcr.microsoft.com/devcontainers/javascript-node:1-20-bullseye",
7+
// Features to add to the dev container. More info: https://containers.dev/features.
8+
// "features": {},
9+
// Use 'forwardPorts' to make a list of ports inside the container available locally.
10+
"forwardPorts": [
11+
5173
12+
],
13+
"portsAttributes": {
14+
"5173": {
15+
"label": "Application",
16+
"onAutoForward": "openPreview"
17+
}
18+
},
19+
// Use 'postCreateCommand' to run commands after the container is created.
20+
"postCreateCommand": "yarn install",
21+
// Start the dev server after the container has started.
22+
// The --host argument is needed to expose the app on the browser
23+
"postAttachCommand": "yarn dev --host",
24+
// Configure tool-specific properties.
25+
"customizations": {
26+
"codespaces": {
27+
"openFiles": [
28+
"README.md",
29+
"resume.json"
30+
]
31+
}
32+
}
33+
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
34+
// "remoteUser": "root"
35+
}

0 commit comments

Comments
 (0)