// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/dotnet
{
	"name": "bonch-calendar",
	// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
	"image": "mcr.microsoft.com/devcontainers/dotnet:1-10.0",
	// Features to add to the dev container. More info: https://containers.dev/features.
	"features": {
		"ghcr.io/devcontainers/features/node:2": {
			"version": "lts",
			"pnpmVersion": "none",
			"nvmVersion": "latest"
		},
		"ghcr.io/devcontainers/features/docker-in-docker:3": {
			"installDockerBuildx": true,
			"version": "latest",
			"dockerDashComposeVersion": "v2"
		}
	},

	// Use 'forwardPorts' to make a list of ports inside the container available locally.
	"forwardPorts": [8000, 8080],
	// "portsAttributes": {
	//		"5001": {
	//			"protocol": "https"
	//		}
	// }

	// Use 'postCreateCommand' to run commands after the container is created.
	"postCreateCommand": {
		"api": "dotnet restore api/BonchCalendar.csproj",
		"app": "cd app && npm install"
	},

	// Configure tool-specific properties.
	"customizations": {
		"vscode": {
			"extensions": [
				"bierner.github-markdown-preview",
				"dbaeumer.vscode-eslint",
				"github.vscode-github-actions",
				"GitHub.vscode-pull-request-github",
				"Gruntfuggly.todo-tree",
				"jock.svg",
				"ms-azuretools.vscode-docker",
				"ms-dotnettools.csdevkit",
				"patcx.vscode-nuget-gallery",
				"saeris.markdown-github-alerts",
				"humao.rest-client"
			]
		}
	}

	// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
	// "remoteUser": "root"
}
