|
| 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/docker-existing-docker-compose |
1 | 3 | { |
2 | | - "name": "crunchloop-nestjs-interview", |
| 4 | + "name": "Existing Docker Compose (Extend)", |
3 | 5 |
|
4 | | - // Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile |
5 | | - "image": "mcr.microsoft.com/devcontainers/typescript-node:0-18", |
| 6 | + // Update the 'dockerComposeFile' list if you have more compose files or use different names. |
| 7 | + // The .devcontainer/docker-compose.yml file contains any overrides you need/want to make. |
| 8 | + "dockerComposeFile": [ |
| 9 | + "../docker-compose.yml", |
| 10 | + "docker-compose.yml" |
| 11 | + ], |
6 | 12 |
|
7 | | - // Set the workspace folder |
8 | | - "workspaceFolder": "/workspaces/${localWorkspaceFolderBasename}", |
| 13 | + // The 'service' property is the name of the service for the container that VS Code should |
| 14 | + // use. Update this value and .devcontainer/docker-compose.yml to the real service name. |
| 15 | + "service": "app", |
9 | 16 |
|
10 | | - // Features to add to the dev container. More info: https://containers.dev/features. |
11 | | - "features": { |
12 | | - "ghcr.io/devcontainers-contrib/features/nestjs-cli:2": {} |
13 | | - }, |
| 17 | + // The optional 'workspaceFolder' property is the path VS Code should open by default when |
| 18 | + // connected. This is typically a file mount in .devcontainer/docker-compose.yml |
| 19 | + "workspaceFolder": "/workspaces/${localWorkspaceFolderBasename}", |
14 | 20 |
|
15 | | - // Use 'forwardPorts' to make a list of ports inside the container available locally. |
16 | | - "forwardPorts": [3000], |
| 21 | + // Features to add to the dev container. More info: https://containers.dev/features. |
| 22 | + "features": { |
| 23 | + "ghcr.io/devcontainers-extra/features/nestjs-cli:2": {} |
| 24 | + } |
17 | 25 |
|
18 | | - // Use 'postCreateCommand' to run commands after the container is created. |
19 | | - "postCreateCommand": "npm install", |
| 26 | + // Use 'forwardPorts' to make a list of ports inside the container available locally. |
| 27 | + // "forwardPorts": [], |
20 | 28 |
|
21 | | - // Configure tool-specific properties. |
22 | | - "customizations": { |
23 | | - "vscode": { |
24 | | - "extensions": [ |
25 | | - "Postman.postman-for-vscode" |
26 | | - ] |
27 | | - } |
28 | | - } |
| 29 | + // Uncomment the next line if you want start specific services in your Docker Compose config. |
| 30 | + // "runServices": [], |
29 | 31 |
|
30 | | - // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root. |
31 | | - // "remoteUser": "root" |
| 32 | + // Uncomment the next line if you want to keep your containers running after VS Code shuts down. |
| 33 | + // "shutdownAction": "none", |
| 34 | + |
| 35 | + // Uncomment the next line to run commands after the container is created. |
| 36 | + // "postCreateCommand": "cat /etc/os-release", |
| 37 | + |
| 38 | + // Configure tool-specific properties. |
| 39 | + // "customizations": {}, |
| 40 | + |
| 41 | + // Uncomment to connect as an existing user other than the container default. More info: https://aka.ms/dev-containers-non-root. |
| 42 | + // "remoteUser": "devcontainer" |
32 | 43 | } |
0 commit comments