devcontainers / devcontainers/features

[Docker-in-Docker] Missing option to restart docker from inside the devcontainer

Aperta
#357 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Shell
Stelle
1.5k
Fork
621
Merge medio
6g 53m
PR unite (30g)
9

Descrizione

Using default devcontainer setup:

"name": "Docker in Docker",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"image": "mcr.microsoft.com/devcontainers/base:bullseye",

"features": {
"ghcr.io/devcontainers/features/docker-in-docker:2": {
"version": "latest",
"enableNonRootDocker": "true",
"moby": "true"
}
}

The problem I experienced is, when I have changed my MTU on my host docker to e.g. 1332 I get connection disconnects inside the containers in my devcontainer environment. This is due to mismachting MTU values. Resetting my MTU on my host to 1500 resolves this problem.

So far this is no problem. Adjusting the MTUs accordingly should solve my issues, but I have to restart the docker daemon inside the devcontainer for that. Trying `systemctl restart docker` yields following message:

> "systemd" is not running in this container due to its overhead.
> Use the "service" command to start services instead. e.g.:
>
> service --status-all

Executing `service --status-all` yields:

> [ ? ] hwclock.sh
> [ - ] procps
> [ - ] rsync
> [ - ] sudo

It's also necesscary to be able to enable IPv6 for Docker ;)

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.