2015-12-02 42 views
4

我们使用Gitlab-ci的官方Windows runner。我们想要上传文物。用Windows Runner上传文物

我们在我们的yaml文件中使用'artifact'关键字来定义需要上传的artefact。当我们承诺这是消息我们得到:

gitlab-ci-multi-runner 0.7.2 (998cf5d) 
WARNING: artifacts is not supported by selected executor and shell 
Using Shell executor... 

因此,这是因为它使用的是Windows machine?这到底是怎么回事?

+1

他们就可以明显的工作(例如运行Windows从cmd.exe /c "dir"的bash命令): https://gitlab.com/gitlab-org/gitlab-ci-multi-runner/merge_requests/52 –

回答

3

目前不支持从Windows Shell cmdpowershell上传工件。经过一段时间的挖掘源,我发现根据gitlab-ci-multi-runner\shells\bash.gobash确实支持它。

对我来说,工作的解决方案是:

  1. 安装巴什(已包括在GIT-SCM)
  2. 添加在bash目录(C:\Program Files (x86)\Git\bin)到您的PATH
  3. 做,如果你键入肯定bash启动bashcmd
  4. 找到你config.toml和修改/添加:

    executor = "shell" 
    shell = "bash" 
    
  5. 重启你的混帐亚军服务

  6. 确保您的构建脚本是在bash语法
+0

这是关于如何使用当前版本上传人工制品的答案。 –