-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Expand file tree
/
Copy pathdevcontainer.json
More file actions
61 lines (61 loc) · 2.03 KB
/
devcontainer.json
File metadata and controls
61 lines (61 loc) · 2.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
{
"name": "Payload Monorepo",
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
"features": {
"ghcr.io/payloadcms/devcontainer-features/mise-bootstrap:1": {},
"ghcr.io/devcontainers/features/docker-in-docker:2": {},
"ghcr.io/devcontainers/features/common-utils:2": {
"configureZshAsDefaultShell": true,
"installZsh": true,
"installOhMyZsh": true,
"installOhMyZshConfig": true,
"upgradePackages": true
}
},
// Runs before feature postCreateCommands so the named volume is writable
// by the time mise-bootstrap tries to install into node_modules.
"onCreateCommand": "sudo chown vscode:vscode ${containerWorkspaceFolder}/node_modules",
// setup.sh auto-detects bind-mount vs volume-clone mode and handles both.
"postCreateCommand": ".devcontainer/setup.sh",
// Only the Next.js dev server should be forwarded
"forwardPorts": [3000],
"portsAttributes": {
"3000": {
"label": "Next Dev Server"
}
},
"customizations": {
"vscode": {
"extensions": [
"anthropic.claude-code",
"dbaeumer.vscode-eslint",
"esbenp.prettier-vscode",
"eamodio.gitlens",
"hverlin.mise-vscode",
"stylelint.vscode-stylelint",
"vitest.explorer",
"ms-playwright.playwright"
],
"settings": {
"terminal.integrated.defaultProfile.linux": "zsh",
"terminal.integrated.profiles.linux": {
"zsh": {
"path": "zsh"
}
},
// Stop VS Code from auto-forwarding every ephemeral port a process opens.
// Only ports in `forwardPorts` above are exposed.
"remote.autoForwardPorts": false
}
}
},
// Allows us to detect whether we are within a devcontainer
"containerEnv": {
"DEVCONTAINER": "true"
},
// node_modules volume: isolates linux-arm64 installs from darwin-arm64 host
// files in bind-mount mode.
"mounts": [
"source=${containerWorkspaceFolderBasename}-node-modules,target=${containerWorkspaceFolder}/node_modules,type=volume"
]
}