features icon indicating copy to clipboard operation
features copied to clipboard

docker-outside-of-docker feature have /usr/share/bash-completion/completions/docker in gzip instead plain text

Open mercuriete opened this issue 1 year ago • 2 comments

docker outside docker have a bashcompletion in gzip format instead of plain text.

that leads to bash completion not working when using in conjunction with:

mcr.microsoft.com/devcontainers/python:1-3.9-bullseye

My suggestion is decompress that file because now gives syntax error because is a binary file.

$ file /usr/share/bash-completion/completions/docker 
/usr/share/bash-completion/completions/docker: gzip compressed data, was "docker", last modified: Mon Jul 22 17:07:26 2024, from Unix, original size modulo 2^32 114580

Thanks.

PS: I can provide more information if you want

PS2:

I did a reproducer here: https://github.com/mercuriete/docker-outside-docker-reproducer

you can see the file is compressed as gzip and bash-completion is not working until you decompress that file.

mercuriete avatar Aug 01 '24 11:08 mercuriete

I create a reproducer here: https://github.com/mercuriete/docker-outside-docker-reproducer

mercuriete avatar Aug 01 '24 23:08 mercuriete

@gauravsaini04 / @prathameshzarkar9 Can either of you help investigate the issue? thanks!

samruddhikhandale avatar Sep 03 '24 21:09 samruddhikhandale

Hi @samruddhikhandale @mercuriete , We have tried to reproduce this issue. It has been observed that the package bash-completion is getting installed by git which we do not have control over. It has default behaviour to download the mentioned file (/usr/share/bash-completion/completions/docker) in gzip format.

prathameshzarkar9 avatar Sep 16 '24 17:09 prathameshzarkar9

Thanks for the update.

We have only added bash-completion tool to the common-utils Feature and unfortunately we don't have control on the types of files it ends up adding. Feel free to reopen the issue if you have any more questions, thanks!

samruddhikhandale avatar Sep 16 '24 20:09 samruddhikhandale

@samruddhikhandale What is your suggestion for tab completion? right now is broken. docker is mostly useless without tab completion because of the hashes or names you need to type trying to remove a container or a volume.

Thanks for your time and for this awesome project.

mercuriete avatar Sep 16 '24 22:09 mercuriete