// For format details, see https://aka.ms/vscode-remote/devcontainer.json or this file's README at:
// https://github.com/microsoft/vscode-dev-containers/tree/v0.112.0/containers/cpp
{
	"name": "C++",
	"dockerFile": "Dockerfile",
	// Due to a limitation in podman, the development container should be executed
	// in "privileged" mode: https://github.com/containers/libpod/issues/4131
	"runArgs": [
		"--privileged"
	],
	"mounts": [
		// "source=${localWorkspaceFolder}/../ugw_sw,target=${containerWorkspaceFolder}/../ugw_sw,type=bind,consistency=delegated",
		"source=prplmesh-vscode-build,target=${containerWorkspaceFolder}/build,type=volume",
		"source=prplmesh-vscode-dind,target=/var/lib/docker,type=volume"
	],
	// "runArgs": [ "--cap-add=SYS_PTRACE", "--security-opt", "seccomp=unconfined" ],
	// Set *default* container specific settings.json values on container create.
	"settings": {
		"terminal.integrated.shell.linux": "/bin/bash"
	},
	// Expose container ports
	"forwardPorts": [
		2222
	],
	// IDs of extensions to install inside the container
	"extensions": [
		"ms-vscode.cpptools",
		"twxs.cmake",
		"eamodio.gitlens",
		"ms-python.python",
		"ms-python.vscode-pylance",
		"redhat.vscode-yaml",
		"streetsidesoftware.code-spell-checker",
		"yzhang.markdown-all-in-one",
		"ms-azuretools.vscode-docker"
	],
	// Define VSCode as the default git editor
	"postCreateCommand": "git config --global core.editor 'code --wait'",
	// Start the docker daemon
	"postStartCommand": "service docker start"
}
