Skip to content

Commit 165eee2

Browse files
myadav00myadav27
authored andcommitted
fix access issue to devconatiner
Signed-off-by: myadav <[email protected]> Signed-off-by: Manoj Kumar Yadav <[email protected]>
1 parent 1d614be commit 165eee2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

.devcontainer/devcontainer.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020
// Use 'postCreateCommand' to run commands after the container is created
2121
"postCreateCommand": "bash .devcontainer/setup.sh",
2222

23+
// Runs each time the container starts/restarts
24+
// Only run these commands if /dev/kvm exists
25+
"postStartCommand": "if [ -e /dev/kvm ]; then sudo chown root:kvm /dev/kvm && sudo chmod 660 /dev/kvm && sudo usermod -aG kvm vscode; else echo 'KVM device not found, skipping...'; fi",
2326
"customizations": {
2427
"vscode": {
2528
"extensions": [

0 commit comments

Comments
 (0)