ghcr.io/devcontainers/features/git:1 changes mode of /tmp to 755 causing "mkdir: cannot create directory ‘/tmp/.X11-unix’: Permission denied"
Évaluation
Cette issue n'a pas encore été évaluée.
Description
Adding feature ghcr.io/devcontainers/features/git:1 causes the mode of /tmp in the container to be changed to 0755.
This is my devcontainer.json
{
"name": "myproj",
"build": {
"dockerfile": "Dockerfile",
"context": ".."
},
"features": {
"ghcr.io/devcontainers/features/git:1": {}
}
}
and this is the Dockerfile
ARG VARIANT="3.11"
FROM mcr.microsoft.com/vscode/devcontainers/python:0-${VARIANT}
RUN ls -la /tmp
It might also be important to mention that I'm using podman. I don't have docker at hand, so I don't know if that plays a role in this bug.
When I do a "Reopen in Container" in vscode I eventually get this error:
...
[1/3] STEP 1/2: FROM mcr.microsoft.com/vscode/devcontainers/python:0-3.11 AS dev_container_auto_added_stage_label
[1/3] STEP 2/2: RUN ls -la /tmp
total 0
drwxrwxrwt. 1 root root 36 Jun 8 2023 .
dr-xr-xr-x. 1 root root 24 Sep 13 19:23 ..
drwxr-xr-x. 1 root root 0 Jun 8 2023 build-features-src
drwxr-xr-x. 1 root root 66 Jun 8 2023 dev-container-features
--> 77f2db5530a2
...
[38726 ms] Start: Run in container: test -e /tmp/.X11-unix/X0
[38727 ms]
[38727 ms]
[38727 ms] Exit code 1
[38727 ms] Start: Run in container: mkdir -p '/tmp/.X11-unix'
[38729 ms]
[38729 ms] mkdir: cannot create directory ‘/tmp/.X11-unix’: Permission denied
[38730 ms] Exit code 1
[38733 ms] Command in container failed: mkdir -p '/tmp/.X11-unix'
[38733 ms] mkdir: cannot create directory ‘/tmp/.X11-unix’: Permission denied
[38734 ms] Exit code 1
When this happens, before canceling, I can "exec" into the container from another terminal and look at /tmp in the container.
$ podman exec -t -i jovial_sutherland /bin/bash
root ➜ / $ ls -ld /tmp/
drwxr-xr-x. 1 root root 80 Sep 13 19:23 /tmp/
Somewhere/somehow the mode of /tmp got changed.
If I drop the git feature the problem does not happen.
- Langage dominant
- Shell
- Étoiles
- 1.5k
- Forks
- 627
- Merge moyen
- 1 j 20 h
- PR mergées (30 j)
- 4
Préparer son environnement
Lance le conteneur de développement du projet dans votre navigateur, avec votre propre compte GitHub.
- Aucun Dockerfile ni fichier Docker Compose
- Aucun modèle de pull request
- Lire le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de devcontainers/features
-
Can the onCreateCommand be run background and use the Output tab instead of the Terminal tab?Ouverte
Difficulté 4/5 3-5 jours Accessibilité débutants 38/100
devcontainers/features#1754 ·
-
use mise for java feature installation or make sdkman configuable to download JDK from mirrosOuverte
Difficulté 4/5 3-5 jours Accessibilité débutants 48/100
devcontainers/features#1730 ·
-
Version resolution over unauthenticated git makes feature installs fail hard, with no fallbackPeut-être pris @v-Kaniska244 l’a pris il y a 48 jours. Ouverte
devcontainers/features#1726 · 2 commentaires · 1 personne assignée ·
-
[docker-in-docker] v4 with iptablesSwitchAtRuntime:true default on Ubuntu 26.04 host/devcontainer image activates iptables-legacy instead of iptables-nftPeut-être à nouveau libre @v-Kaniska244 l’a pris il y a 66 jours, et aucune pull request n’est ouverte. Ouverte
devcontainers/features#1709 · 1 réaction · 1 personne assignée ·
-
Difficulté 4/5 3-5 jours Accessibilité débutants 45/100
devcontainers/features#1707 ·
Toutes les issues de devcontainers/features
Issues similaires
-
Difficulté 1/5 Moins d'une heure Accessibilité débutants 92/100
Les mainteneurs répondent en général sous 1 jour
-
[Resource]: Valpas Keep AwakeOuverteresource-submission validation-passed
Difficulté 1/5 Moins d'une heure Accessibilité débutants 67/100
hesreallyhim/awesome-claude-code#3264 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
area: install bug good first issue hacktoberfest
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
Les mainteneurs répondent en général sous 3 jours
-
Good first issue
Difficulté 2/5 1-3 heures Accessibilité débutants 75/100
armbian/build#11107 · 2 commentaires ·
Les mainteneurs répondent en général sous 1 jour
-
Bug: Veracrypt failing againOuvertebug
Difficulté 2/5 1-3 heures Accessibilité débutants 65/100
wimpysworld/deb-get#2069 ·
Les mainteneurs répondent en général sous 5 jours