Skip to content

Commit 31a2482

Browse files
committed
Fix automatic remote user id, base image test
1 parent 8d0ce2a commit 31a2482

3 files changed

Lines changed: 3 additions & 7 deletions

File tree

images/base/.devcontainer/devcontainer.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@
77
"ghcr.io/devcontainers/features/common-utils:2": {
88
"installZsh": "false",
99
"username": "developer",
10-
"userUid": "1000",
11-
"userGid": "1000",
1210
"upgradePackages": "true"
1311
},
1412
"ghcr.io/devcontainers/features/git:1": {

images/base/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Base devcontainer image with common tools.
1414

1515
| Tool | Source |
1616
| --- | --- |
17-
| common-utils (`developer` user, UID/GID 1000) | [devcontainers/features/common-utils](https://github.com/devcontainers/features/tree/main/src/common-utils) |
17+
| common-utils (`developer` user) | [devcontainers/features/common-utils](https://github.com/devcontainers/features/tree/main/src/common-utils) |
1818
| git | [devcontainers/features/git](https://github.com/devcontainers/features/tree/main/src/git) |
1919
| Node.js 24 + npm | [devcontainers/features/node](https://github.com/devcontainers/features/tree/main/src/node) |
2020
| prettier | [prettier](https://www.npmjs.com/package/prettier) |

images/base/test-project/test.sh

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,8 @@ cd "$(dirname "$0")"
33

44
. ./test-utils.sh developer
55

6-
# User checks
7-
check "non-root-user" id ${USERNAME}
8-
check "uid" test "$(id -u ${USERNAME})" = "1000"
9-
check "gid" test "$(id -g ${USERNAME})" = "1000"
6+
# User check
7+
check "remote-user" test "$(whoami)" = "${USERNAME}"
108

119
# Tool checks
1210
check "git" git --version

0 commit comments

Comments
 (0)