firecow / gitlab-ci-local

Tired of pushing to test your .gitlab-ci.yml?
MIT License
2.31k stars 130 forks source link

No output/log from docker job in Windows #1383

Open bcouetil opened 1 day ago

bcouetil commented 1 day ago

Hello, long time no see. Still amazed by this tool šŸ˜

On my current pro project, I went to uncharted territory : GCL on Windows, using Powershell (or cmd if needed).

It seems to work pretty well, except that I have no output/log at all from the job/container itself :

PS C:> gitlab-ci-local.exe show-env

Using fallback linux user id
parsing and downloads finished in 1.36 s.
json schema validated in 138 ms
show-env starting alpine:3.16 (test)
show-env > still running...
show-env copied to docker volumes in 19 s
show-env finished in 27 s

 PASS  show-env

When script is OK, result is PASS. When script is KO, result is not. As if everything was indeed run, but with quiet=true...

And for the record, inside a docker container manually launched, everything is fine.

PS C:> docker run -it alpine:3.16
/ # 
/ #
/ # ls
bin    home   mnt    root   srv    usr
dev    lib    opt    run    sys    var
etc    media  proc   sbin   tmp
/ # ls *
bin:
arch
...

Minimal .gitlab-ci.yml illustrating the issue

show-env:
  image: alpine:3.16
  script:
    - echo "test"
    - ls
    - env | sort

Expected behavior

Some output/log from the job.

Host information

Windows / Powershell gitlab-ci-local 4.53.0

Containerd binary

Latest Rancher Desktop installed with Docker compatibility

firecow commented 1 day ago

We recommend git bash terminal for windows users. I can't say that it's going to solve this issue, but it's worth a shot

bcouetil commented 1 day ago

I totally understand. But on this PC, there is a proxy, and I did not manage to get internet within git bash or WSL2 šŸ˜“