prulloac/devcontainer-features

[BUG]: Crashes if using "remoteUser": "root",

Opened this issue · 0 comments

Description of the bug

error log:

===========================================================================
 => ERROR [dev_containers_target_stage 11/12] RUN --mount=type=bind,from=  3.4s
------
 > [dev_containers_target_stage 11/12] RUN --mount=type=bind,from=dev_containers_feature_content_source,source=bun_6,target=/tmp/build-features-src/bun_6     cp -ar /tmp/build-features-src/bun_6 /tmp/dev-container-features  && chmod -R 0755 /tmp/dev-container-features/bun_6  && cd /tmp/dev-container-features/bun_6  && chmod +x ./devcontainer-features-install.sh  && ./devcontainer-features-install.sh  && rm -rf /tmp/dev-container-features/bun_6:
0.293 ===========================================================================
0.293 Feature       : Bun
0.293 Description   : Installs Bun (Javascript runtime written in zig)
0.293 Id            : ghcr.io/prulloac/devcontainer-features/bun
0.293 Version       : 1.1.2
0.293 Documentation : https://github.com/prulloac/devcontainer-features/tree/main/src/bun
0.293 Options       :
0.293     USENPM="false"
0.293 ===========================================================================
0.294 bash: cannot set terminal process group (1): Inappropriate ioctl for device
0.294 bash: no job control in this shell
######################################################################## 100.0%     
3.307 bun was installed successfully to /usr/local/bin/bun 
3.310 Run 'bun --help' to get started
3.318 bash: /home/root/.zshenv: No such file or directory
3.318 ERROR: Feature "Bun" (ghcr.io/prulloac/devcontainer-features/bun) failed to install! Look at the documentation at https://github.com/prulloac/devcontainer-features/tree/main/src/bun for help troubleshooting this error.
------
Dockerfile.extended:85
--------------------
  84 |     ENV PATH="/usr/local/share/nvm/current/bin:${PATH}"
  85 | >>> RUN --mount=type=bind,from=dev_containers_feature_content_source,source=bun_6,target=/tmp/build-features-src/bun_6 \
  86 | >>>     cp -ar /tmp/build-features-src/bun_6 /tmp/dev-container-features \
  87 | >>>  && chmod -R 0755 /tmp/dev-container-features/bun_6 \
  88 | >>>  && cd /tmp/dev-container-features/bun_6 \
  89 | >>>  && chmod +x ./devcontainer-features-install.sh \
  90 | >>>  && ./devcontainer-features-install.sh \
  91 | >>>  && rm -rf /tmp/dev-container-features/bun_6
  92 |     
--------------------
ERROR: failed to solve: process "/bin/sh -c cp -ar /tmp/build-features-src/bun_6 /tmp/dev-container-features  && chmod -R 0755 /tmp/dev-container-features/bun_6  && cd /tmp/dev-container-features/bun_6  && chmod +x ./devcontainer-features-install.sh  && ./devcontainer-features-install.sh  && rm -rf /tmp/dev-container-features/bun_6" did not complete successfully: exit code: 1
[15424 ms] Error: Command failed: docker buildx build --load --build-context dev_containers_feature_content_source=/tmp/devcontainercli-root/container-features/0.67.0-1723648137277 --build-arg _DEV_CONTAINERS_BASE_IMAGE=mcr.microsoft.com/devcontainers/base:bookworm --build-arg _DEV_CONTAINERS_IMAGE_USER=root --build-arg _DEV_CONTAINERS_FEATURE_CONTENT_SOURCE=dev_container_feature_content_temp --target dev_containers_target_stage -f /tmp/devcontainercli-root/container-features/0.67.0-1723648137277/Dockerfile.extended -t vsc-mage-ai-e58b6562b3e35745ebc7f74d1db89f29492c82e024f29c20855a12b006303f94-features /tmp/devcontainercli-root/empty-folder
[15424 ms]     at ptA (/root/.vscode-remote-containers/dist/dev-containers-cli-0.381.0/dist/spec-node/devContainersSpecCLI.js:465:1260)
[15425 ms]     at NH (/root/.vscode-remote-containers/dist/dev-containers-cli-0.381.0/dist/spec-node/devContainersSpecCLI.js:465:1002)
[15425 ms]     at async KtA (/root/.vscode-remote-containers/dist/dev-containers-cli-0.381.0/dist/spec-node/devContainersSpecCLI.js:482:3771)
[15425 ms]     at async eB (/root/.vscode-remote-containers/dist/dev-containers-cli-0.381.0/dist/spec-node/devContainersSpecCLI.js:482:4886)
[15425 ms]     at async hrA (/root/.vscode-remote-containers/dist/dev-containers-cli-0.381.0/dist/spec-node/devContainersSpecCLI.js:663:200)
[15425 ms]     at async lrA (/root/.vscode-remote-containers/dist/dev-containers-cli-0.381.0/dist/spec-node/devContainersSpecCLI.js:662:13452)
[15439 ms] Exit code 1
[15440 ms] Start: Run: docker rm -f 56331aeac55549543971e793eff33980e58134482a28da1d4d52fef117993c6d
[15443 ms] Command failed: node /root/.vscode-remote-containers/dist/dev-containers-cli-0.381.0/dist/spec-node/devContainersSpecCLI.js up --container-session-data-folder /tmp/devcontainers-76e773a7-db4f-49d9-b50d-cf77f8b7fb4e1723648132384 --workspace-folder /workspaces/mage-ai --workspace-mount-consistency cached --id-label vsch.local.repository=https://github.com/merchanttech/mage-ai.git/tree/dev --id-label vsch.local.repository.volume=mage-ai-dev-de36378c2b993e27f70c8d5a84bf03417f75a4ffdcb2e068a0c0898b91263e6a --id-label vsch.local.repository.folder=mage-ai --id-label devcontainer.config_file=/workspaces/mage-ai/.devcontainer/devcontainer.json --log-level debug --log-format json --config /workspaces/mage-ai/.devcontainer/devcontainer.json --override-config /tmp/devcontainer-e5034ac1-0797-4982-bb95-397ef9f8380e.json --default-user-env-probe loginInteractiveShell --mount type=volume,source=mage-ai-dev-de36378c2b993e27f70c8d5a84bf03417f75a4ffdcb2e068a0c0898b91263e6a,target=/workspaces,external=true --mount type=volume,source=vscode,target=/vscode,external=true --mount type=bind,source=\\wsl.localhost\Ubuntu\mnt\wslg\runtime-dir\wayland-0,target=/tmp/vscode-wayland-c45d7cb2-4112-4aa3-b462-c35e8f473a91.sock --skip-post-create --update-remote-user-uid-default off --mount-workspace-git-root --include-configuration --include-merged-configuration
[15444 ms] Exit code 1
[15563 ms] Container server terminated (code: 137, signal: null).

Steps To Reproduce

use the following devcontainer.json

{
	"name": "Python, HTML & Typescript",
	"image": "mcr.microsoft.com/devcontainers/base:bookworm",
	"features": {
		"ghcr.io/devcontainers/features/docker-in-docker:2": {},
		"ghcr.io/prulloac/devcontainer-features/bun:1": {},
		"ghcr.io/devcontainers/features/node:1": {},
		"ghcr.io/devcontainers/features/common-utils:2": {},
		"ghcr.io/devcontainers/features/python:1": {"version": "3.10"},
		"ghcr.io/devcontainers/features/github-cli:1": {},
		"ghcr.io/jungaretti/features/make:1": {},
		"ghcr.io/devcontainers-contrib/features/poetry:2": {}
	},
	"customizations": {"vscode": {"extensions": ["ms-python.python","charliermarsh.ruff"]}},
	"remoteUser": "root",
	"postCreateCommand": "chmod +x ./scripts/startup.sh && ./scripts/startup.sh"
}

Additional Information

No response