GitLab-CI Multi Runner php composer缓存 [英] GitLab-CI Multi Runner php composer cache

查看:834
本文介绍了GitLab-CI Multi Runner php composer缓存的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用gitlab-ci-multi-runner和docker容器。一切都很好,但是docker容器不保留 composer 缓存,所以在每次运行 composer 下重新下载依赖项,再次,这需要很多时间。是否有任何方法配置 gitlab-ci-runner docker容器以保留 composer

I'm using gitlab-ci-multi-runner with docker containers. Everything is going fine, but docker containers don't keep the composer cache so in every run composer downloads dependencies again and again, which takes a lot of time. Is there any way to configure gitlab-ci-runner docker container to keep the composer cache or mount a volume on each run where the composer cache is kept?

推荐答案

您可以修改 composer

这个存储是持久的,可以跨容器共享。

That storage is persistent and can be shared across containers.

引用:

  • https://gitlab.com/gitlab-org/gitlab-ci-multi-runner/blob/master/docs/configuration/advanced-configuration.md#volumes-in-the-runnersdocker-section
  • https://docs.docker.com/userguide/dockervolumes/

这篇关于GitLab-CI Multi Runner php composer缓存的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆