Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is "docker-in-docker" template correct? #73

Closed
dzeyelid opened this issue Dec 5, 2022 · 2 comments · Fixed by #78
Closed

Is "docker-in-docker" template correct? #73

dzeyelid opened this issue Dec 5, 2022 · 2 comments · Fixed by #78
Assignees
Labels
bug Something isn't working

Comments

@dzeyelid
Copy link

dzeyelid commented Dec 5, 2022

When I created an environment by selecting "Docker in Docker" in "Add Dev Container Configuration Files" in VS Code, the template created the devcontainer.json below that has docker-from-docker in features.

In the environment, the docker engine shows its instance when running docker ps. It looks like "docker-from-docker" behavior, not "docker-in-docker'.

// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/docker-in-docker
{
	"name": "Docker in Docker",
	"image": "mcr.microsoft.com/devcontainers/base:bullseye",
	"features": {
		"ghcr.io/devcontainers/features/common-utils:1": {
			"installZsh": "true",
			"upgradePackages": "false",
			"uid": "1000",
			"gid": "1000",
			"installOhMyZsh": "true",
			"nonFreePackages": "true"
		},
		"ghcr.io/devcontainers/features/docker-from-docker:1": {
			"version": "latest",
			"enableNonRootDocker": "true",
			"moby": "true"
		}
	}

	// Use 'forwardPorts' to make a list of ports inside the container available locally.
	// "forwardPorts": [],

	// Use 'postCreateCommand' to run commands after the container is created.
	// "postCreateCommand": "docker --version",

	// Configure tool-specific properties.
	// "customizations": {},

	// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
	// "remoteUser": "root"
}

So, I changed from docker-from-docker to docker-in-docker inside features configuration, then the behavior is suited to my thought.

What do you think?

Thank you for these convenient templates!

Best regards,

@samruddhikhandale
Copy link
Member

Hi @dzeyelid 👋

Thanks for reporting.

So, I changed from docker-from-docker to docker-in-docker inside features configuration, then the behavior is suited to my thought.
What do you think?

Yep, that should be docker-in-docker. Looks like this was a regression during migration, working on fixing it.

@samruddhikhandale
Copy link
Member

Closed by the bot as it's fixed. 🚀

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants