Is it possible to invalidate the assembly cache in this thread?

I am using Gitlab CI in one of my projects and am facing the following problem:

  • My masterbuild will work with a lot of time ...
  • I click on a new branch built from the master (without new commits) and click on it, build work.

I think this is due to the creation of the cache, because the code base is exactly the same ... The last valid build cache may cause the current code base to crash ...

Is there a way to clear the assembly cache for a specific branch? In my case master? From the API?

+4
source share
2 answers

, Gitlab Twitter: https://twitter.com/gitlab/status/832674380790394880

gitlab.com, . .gitlab-ci.yml , cache:key.

cache:key , , , 😊.

.gitlab-ci.yml:

my-asset-build:
  cache:
    key: "$CI_COMMIT_REF_NAME-assets"

ref ( RE ) !

Gitlab Twitter!

, , : https://docs.gitlab.com/ce/ci/variables/README.html#9-0-renaming

, Gitlab 10.4, "Clear runner cache" . , , .

+7

Source: https://habr.com/ru/post/1670087/


All Articles