Skip to content
代码片段 群组 项目
提交 c0e3496c 编辑于 作者: Thong Kuah's avatar Thong Kuah
浏览文件

Skip check precompiled assets locally

It is rare we add a new precompiled asset nowadays. For each asset,
sprockets currently checks every asset path directory (we have about 9K)
which is very slow. So disable this check locally.
上级 67a4f2fc
No related branches found
No related tags found
无相关合并请求
......@@ -68,6 +68,7 @@ variables:
ELASTIC_URL: "http://elastic:changeme@elasticsearch:9200"
DOCKER_VERSION: "20.10.1"
CACHE_CLASSES: "true"
CHECK_PRECOMPILED_ASSETS: "true"
FF_USE_FASTZIP: "true"
# Preparing custom clone path to reduce space used by all random forks
......
......@@ -23,6 +23,9 @@
# Configure static asset server for tests with Cache-Control for performance
config.assets.compile = false if ENV['CI']
# There is no need to check if assets are precompiled locally
# To debug AssetNotPrecompiled errors locally, set CHECK_PRECOMPILED_ASSETS to true
config.assets.check_precompiled_asset = Gitlab::Utils.to_boolean(ENV['CHECK_PRECOMPILED_ASSETS'], default: false)
config.public_file_server.enabled = true
config.public_file_server.headers = { 'Cache-Control' => 'public, max-age=3600' }
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册