Skip to content

Commit e888539

Browse files
committed
Add port attribute
1 parent 04d5509 commit e888539

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

.devcontainer/devcontainer.json

+10-5
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,22 @@
1212
"forwardPorts": [
1313
3000
1414
],
15-
// Use 'postCreateCommand' to run commands after the container is created.
15+
"portsAttributes": {
16+
"3000": {
17+
"label": "Blog",
18+
"onAutoForward": "openPreview"
19+
}
20+
},
1621
"onCreateCommand": "pnpm self-update",
17-
"postCreateCommand": "pnpm install --config.confirmModulesPurge=false",
18-
// "postStartCommand": "pnpm dev",
22+
"updateContentCommand": "pnpm install --config.confirmModulesPurge=false",
23+
"postAttachCommand": "pnpm dev",
1924

2025
// Configure tool-specific properties.
2126
"customizations": {
2227
"jetbrains": {
23-
"backend": "Rider",
28+
"backend": "Rider"
2429
}
25-
},
30+
}
2631
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
2732
// "remoteUser": "root"
2833
}

0 commit comments

Comments
 (0)