diff --git a/src/libstore/binary-cache-store.cc b/src/libstore/binary-cache-store.cc index 3857ed93e..dacdeb3f5 100644 --- a/src/libstore/binary-cache-store.cc +++ b/src/libstore/binary-cache-store.cc @@ -8,6 +8,7 @@ #include "sync.hh" #include "worker-protocol.hh" #include "nar-accessor.hh" +#include "nar-info-disk-cache.hh" #include @@ -98,6 +99,9 @@ void BinaryCacheStore::addToCache(const ValidPathInfo & info, state_->pathInfoCache.upsert(narInfo->path, std::shared_ptr(narInfo)); } + if (diskCache) + diskCache->upsertNarInfo(getUri(), std::shared_ptr(narInfo)); + stats.narInfoWrite++; }