aboutsummaryrefslogtreecommitdiffhomepage
path: root/.devcontainer/devcontainer.json
diff options
context:
space:
mode:
Diffstat (limited to '.devcontainer/devcontainer.json')
-rw-r--r--.devcontainer/devcontainer.json39
1 files changed, 39 insertions, 0 deletions
diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json
new file mode 100644
index 0000000..e71762d
--- /dev/null
+++ b/.devcontainer/devcontainer.json
@@ -0,0 +1,39 @@
+// For format details, see https://aka.ms/devcontainer.json
+{
+ "name": "ZLUDA",
+ "build": {
+ "dockerfile": "Dockerfile"
+ },
+ "securityOpt": [
+ "seccomp=unconfined"
+ ],
+ // Make NVIDIA and AMD GPUs available
+ "runArgs": [
+ // Uncomment on newer docker/podman
+ //"--runtime=nvidia",
+ "--device=/dev/kfd",
+ "--device=/dev/dri",
+ "--group-add=video"
+ ],
+ // Cache cargo packages and compiled ZLUDA kernels
+ "initializeCommand": "mkdir -p ${localEnv:HOME}/.cargo/git ${localEnv:HOME}/.cargo/registry ${localEnv:HOME}/.cache/ZLUDA",
+ "mounts": [
+ {
+ "source": "${localEnv:HOME}/.cargo/git",
+ "target": "/root/.cargo/git",
+ "type": "bind"
+ },
+ {
+ "source": "${localEnv:HOME}/.cargo/registry",
+ "target": "/root/.cargo/registry",
+ "type": "bind"
+ },
+ {
+ "source": "${localEnv:HOME}/.cache/ZLUDA",
+ "target": "/root/.cache/ZLUDA",
+ "type": "bind"
+ }
+ ],
+ // Rootless docker requires logging as root: https://aka.ms/dev-containers-non-root.
+ "remoteUser": "root"
+} \ No newline at end of file