-
Notifications
You must be signed in to change notification settings - Fork 222
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
build --push
pushes wrong image name
#612
Comments
After checking the code, it looks like the CLI doesn't pass all desired image names to the Shouldn't be too complicated to fix that behaviour. |
Is anyone engaged in this? |
@chrmarti @samruddhikhandale hello, good morning. I've just tried to build a multi-platform image (requiring --push), now being held up by this issue again. Can someone please have a look at this? Edit: Some output for visualization
|
FYI, here's a wildlife example. https://github.com/rocker-org/devcontainer-images/actions/runs/8848242588/job/24297700205#step:7:22 devcontainer build \
--workspace-folder work/r-ver/4.3 \
--platform linux/amd64,linux/arm64 \
--cache-from ghcr.io/rocker-org/devcontainer/r-ver:4.3 \
--image-name ghcr.io/rocker-org/devcontainer/r-ver:4.3 \
--push true Converted to... docker buildx build --platform linux/amd64,linux/arm64 --push --build-arg BUILDKIT_INLINE_CACHE=1 -f /tmp/devcontainercli-runner/container-features/0.59.1-1714134566730/Dockerfile-with-features -t ghcr.io/rocker-org/devcontainer/r-ver:4.3 --target dev_containers_target_stage --cache-from ghcr.io/rocker-org/devcontainer/r-ver:4.3 --build-arg VARIANT=4.3 --build-arg BASE_IMAGE=docker.io/rocker/r-ver --build-context dev_containers_feature_content_source=/tmp/devcontainercli-runner/container-features/0.59.1-1714134566730 --build-arg _DEV_CONTAINERS_BASE_IMAGE=dev_container_auto_added_stage_label --build-arg _DEV_CONTAINERS_IMAGE_USER=root --build-arg _DEV_CONTAINERS_FEATURE_CONTENT_SOURCE=dev_container_feature_content_temp /home/runner/work/devcontainer-images/devcontainer-images/work/r-ver/4.3 |
@eitsupi that leaves me a little bit clueless now 😲 I basically copied that command: The only diff I see at the moment: We're not building from a Dockerfile. For ref: // For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/typescript-node
{
"name": "Dev",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"image": "mcr.microsoft.com/devcontainers/typescript-node:1-20-bookworm",
"features": {
"ghcr.io/devcontainers/features/kubectl-helm-minikube:1": {},
"ghcr.io/prulloac/devcontainer-features/bun:1": {
"version": "1.1.8"
},
"ghcr.io/rio/features/k9s": {}
},
"customizations": {
"vscode": {
"extensions": [
"cpreston321.nuxt-vscode",
"Vue.volar",
"redhat.vscode-yaml",
"GitLab.gitlab-workflow",
"vitest.explorer",
"humao.rest-client",
"dbaeumer.vscode-eslint",
"esbenp.prettier-vscode",
"sibiraj-s.vscode-scss-formatter",
"syler.sass-indented",
"formulahendry.auto-rename-tag",
"formulahendry.auto-close-tag",
"christian-kohler.path-intellisense"
]
}
}
} |
Thanks for the ping, we already have #812 open to fix this issue. // cc @prathameshzarkar9 Can you help address the PR review feedback so that we can merge the PR sooner? thanks! |
Closing as completed with #812 |
When doing a
devcontainer build --workspace-folder . --image-name my/image:tag --push
the wrong image (e.g.vsc-devcontainer-839d9d58687bee078581a54501bbf0ec1d94e4e7a1e7d74dd0f0f02c09f29e0c-features
) is pushed instead. The name used seems to be the same as if you do not specify a--image-name
at all.The only workaround is to build the image without
--push
and push it "manually" after the invocation ofdevcontainer build
. However this can't be used to build and push a multiarch image in buildx, as this needs to be pushed directly out of buildx.The text was updated successfully, but these errors were encountered: