firecow / gitlab-ci-local

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

Add support to docker windows mode #739

Open Mwoua opened 1 year ago

Mwoua commented 1 year ago

Error output

build_windows            starting local_image_windows:latest (build)Error: Command failed with exit code 1: docker create --volume=gcl-build_windows-955953-build:/gcl-builds --volume=gcl-build_windows-955953-tmp:/tmp/gitlab-ci-local-file-variables-op-thz-dev-thzcam-ino_cameraapi-955953 docker.io/firecow/gitlab-ci-local-util bash -c chown 0:0 -R /gcl-builds/ && chmod a+rw -R /gcl-builds/ && chmod a+rw -R /tmp/
Unable to find image 'firecow/gitlab-ci-local-util:latest' locally
latest: Pulling from firecow/gitlab-ci-local-util
image operating system "linux" cannot be used on this platform
    at makeError (C:\snapshot\firecow-gitlab-ci-local\node_modules\execa\lib\error.js:60:11)
    at handlePromise (C:\snapshot\firecow-gitlab-ci-local\node_modules\execa\index.js:118:26)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at Job.start (C:\snapshot\firecow-gitlab-ci-local\src\job.ts:355:43)

Minimal .gitlab-ci.yml illustrating the issue

---
job:
  image: local_image_windows:latest
  script:
    - echo "Heya"

Expected behavior Build is started

Host information Windows 10 gitlab-ci-local 4.37.0

Additional context I am a docker newbie, so it may be an issue on my side
my docker is set to run windows container, so it cannot pull your linux image, and if I switch to linux container, first step is OK, but then it cannot use the windows container to actually build

firecow commented 1 year ago

GCL doesn't support docker in "windows" mode.

You can create a feature request or rename this issue.