Good day.

There was a question - How to transfer a file between runners gitlabCi.

File - .gitlab-ci.yml

stages: - build - deploy - testing build:win: stage: build script: - 'chcp 65001' - msbuild Test-project.sln artifacts: untracked: false paths: - Test-project\bin\Debug\Test-project.exe expire_in: 1 week deploy: stage: deploy script: ? 

So, at the deploy stage, I want to take the resulting arithact from the gitlab, and put it on a runner. How can I do it.

PS While I was rummaging through the documentation, I saw that there was some kind of stable link to the last collected artifact, but now I have been unable to stumble upon this for 3 days. Everything happens on Windows machines, except for finding the Gitlab itself.

    2 answers 2

    No one knows how, but I found a solution, the mechanism of which is not yet clear to me.

    The essence is as follows:

     deploy: stage: deploy tags: - linux 

    There is no tricky script or anything else. Simply, after execution, the binary turned out to be on another machine, where it was not even possible to assemble it.

    And for the purposes of testing the project, that's enough.

      Artifacts can be transferred between stages. To do this in the stage you need to specify the dependence on the stage where the artifact was going

       deploy: stage: deploy dependencies: - build:win tags: - linux