Skip to content

Commit

Permalink
Added new devcontainer configs (ivy-llc#13795)
Browse files Browse the repository at this point in the history
* Added new devcontainer configs

* Disabled `upgradePackages` in `common-utils`
  • Loading branch information
KareemMAX authored Apr 7, 2023
1 parent 0ec813b commit 5222595
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 19 deletions.
21 changes: 11 additions & 10 deletions .devcontainer/build/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@
}
},

"postCreateCommand": "bash .devcontainer/post_create_commands.sh"
"postCreateCommand": {
"post_create": "bash .devcontainer/post_create_commands.sh",
"bashrc": "echo \"alias python=python3\" >> ~/.bashrc"
},

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],
Expand All @@ -30,14 +33,12 @@
// "mounts": [ "source=/var/run/docker.sock,target=/var/run/docker.sock,type=bind" ],

// Uncomment to connect as a non-root user if you've added one. See https://aka.ms/vscode-remote/containers/non-root.
// "remoteUser": "vscode"

// Uncomment to allow connection to JetBrians Gateway
// "features": {
// "ghcr.io/devcontainers/features/sshd:1": {
// "version": "latest"
// }
// }

"remoteUser": "vscode",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"upgradePackages": false
},
"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {}
}
}

13 changes: 11 additions & 2 deletions .devcontainer/build_gpu/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@
}
},

"postCreateCommand": "bash .devcontainer/post_create_commands.sh"
"postCreateCommand": {
"post_create": "bash .devcontainer/post_create_commands.sh",
"bashrc": "echo \"alias python=python3\" >> ~/.bashrc"
},

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],
Expand All @@ -30,5 +33,11 @@
// "mounts": [ "source=/var/run/docker.sock,target=/var/run/docker.sock,type=bind" ],

// Uncomment to connect as a non-root user if you've added one. See https://aka.ms/vscode-remote/containers/non-root.
// "remoteUser": "vscode"
"remoteUser": "vscode",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"upgradePackages": false
},
"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {}
}
}
15 changes: 12 additions & 3 deletions .devcontainer/image/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,11 @@
}
},

"postCreateCommand": "bash .devcontainer/post_create_commands.sh",
"initializeCommand": "docker pull unifyai/ivy:latest"
"postCreateCommand": {
"post_create": "bash .devcontainer/post_create_commands.sh",
"bashrc": "echo \"alias python=python3\" >> ~/.bashrc"
},
"initializeCommand": "docker pull unifyai/ivy:latest",

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],
Expand All @@ -23,5 +26,11 @@
// "mounts": [ "source=/var/run/docker.sock,target=/var/run/docker.sock,type=bind" ],

// Uncomment to connect as a non-root user if you've added one. See https://aka.ms/vscode-remote/containers/non-root.
// "remoteUser": "vscode"
"remoteUser": "vscode",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"upgradePackages": false
},
"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {}
}
}
16 changes: 12 additions & 4 deletions .devcontainer/image_gpu/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,11 @@

"runArgs": ["--gpus","all"],

"postCreateCommand": "bash .devcontainer/post_create_commands.sh",
"initializeCommand": "docker pull unifyai/ivy:latest"
"postCreateCommand": {
"post_create": "bash .devcontainer/post_create_commands.sh",
"bashrc": "echo \"alias python=python3\" >> ~/.bashrc"
},
"initializeCommand": "docker pull unifyai/ivy:latest",

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],
Expand All @@ -25,6 +28,11 @@
// "mounts": [ "source=/var/run/docker.sock,target=/var/run/docker.sock,type=bind" ],

// Uncomment to connect as a non-root user if you've added one. See https://aka.ms/vscode-remote/containers/non-root.
// "remoteUser": "vscode"

"remoteUser": "vscode",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"upgradePackages": false
},
"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {}
}
}

0 comments on commit 5222595

Please sign in to comment.