ci: aggressive caching for front related jobs
Part-of: <https://dev.funkwhale.audio/funkwhale/funkwhale/-/merge_requests/2286>
This commit is contained in:
parent
6662408fb3
commit
f027c8d04b
|
@ -20,6 +20,16 @@ variables:
|
|||
GIT_DEPTH: "5"
|
||||
FF_DISABLE_UMASK_FOR_DOCKER_EXECUTOR: "true"
|
||||
|
||||
.shared_caches:
|
||||
# Cache for front related jobs
|
||||
front_cache: &front_cache
|
||||
- key: front-yarn
|
||||
paths: [$YARN_CACHE_FOLDER]
|
||||
- key:
|
||||
prefix: front-node_modules
|
||||
files: [front/yarn.lock]
|
||||
paths: [front/node_modules]
|
||||
|
||||
default:
|
||||
tags:
|
||||
- docker
|
||||
|
@ -60,8 +70,7 @@ review_front:
|
|||
environment:
|
||||
name: review/front/$CI_COMMIT_REF_NAME
|
||||
url: http://$CI_PROJECT_NAMESPACE.pages.funkwhale.audio/-/$CI_PROJECT_NAME/-/jobs/$CI_JOB_ID/artifacts/front-review/index.html
|
||||
cache:
|
||||
paths: [$YARN_CACHE_FOLDER]
|
||||
cache: *front_cache
|
||||
before_script:
|
||||
- mkdir front-review
|
||||
- cd front
|
||||
|
@ -163,8 +172,7 @@ lint_front:
|
|||
- changes: [front/**/*]
|
||||
|
||||
image: $CI_REGISTRY/funkwhale/ci/node-python:18
|
||||
cache:
|
||||
paths: [$YARN_CACHE_FOLDER]
|
||||
cache: *front_cache
|
||||
before_script:
|
||||
- cd front
|
||||
- yarn install --frozen-lockfile
|
||||
|
@ -227,8 +235,7 @@ test_front:
|
|||
- changes: [front/**/*]
|
||||
|
||||
image: $CI_REGISTRY/funkwhale/ci/node-python:18
|
||||
cache:
|
||||
paths: [$YARN_CACHE_FOLDER]
|
||||
cache: *front_cache
|
||||
before_script:
|
||||
- cd front
|
||||
- yarn install --frozen-lockfile
|
||||
|
@ -307,8 +314,7 @@ build_front:
|
|||
image: $CI_REGISTRY/funkwhale/ci/node-python:18
|
||||
variables:
|
||||
<<: *keep_git_files_permissions
|
||||
cache:
|
||||
paths: [$YARN_CACHE_FOLDER]
|
||||
cache: *front_cache
|
||||
before_script:
|
||||
- cd front
|
||||
- yarn install --frozen-lockfile
|
||||
|
|
Loading…
Reference in New Issue