mirror of
https://github.com/NixOS/nix.git
synced 2025-11-21 09:49:36 +01:00
libstore: Make all StoreConfig::getReference implementations return store parameters
These stragglers have been accidentally left out when implementing the StoreConfig::getReference. Also HttpBinaryCacheStore::getReference now returns the actual store parameters, not the cacheUri parameters.
This commit is contained in:
parent
3bf1268ac6
commit
426a72c9cf
6 changed files with 44 additions and 2 deletions
|
|
@ -39,7 +39,7 @@ StoreReference HttpBinaryCacheStoreConfig::getReference() const
|
|||
.scheme = cacheUri.scheme,
|
||||
.authority = cacheUri.renderAuthorityAndPath(),
|
||||
},
|
||||
.params = cacheUri.query,
|
||||
.params = getQueryParams(),
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -48,6 +48,7 @@ struct DummyStoreConfig : public std::enable_shared_from_this<DummyStoreConfig>,
|
|||
StoreReference::Specified{
|
||||
.scheme = *uriSchemes().begin(),
|
||||
},
|
||||
.params = getQueryParams(),
|
||||
};
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -262,6 +262,7 @@ StoreReference S3BinaryCacheStoreConfig::getReference() const
|
|||
.scheme = *uriSchemes().begin(),
|
||||
.authority = bucketName,
|
||||
},
|
||||
.params = getQueryParams(),
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -61,13 +61,17 @@ StoreReference UDSRemoteStoreConfig::getReference() const
|
|||
* to be more compatible with older versions of nix. Some tooling out there
|
||||
* tries hard to parse store references and it might not be able to handle "unix://". */
|
||||
if (path == settings.nixDaemonSocketFile)
|
||||
return {.variant = StoreReference::Daemon{}};
|
||||
return {
|
||||
.variant = StoreReference::Daemon{},
|
||||
.params = getQueryParams(),
|
||||
};
|
||||
return {
|
||||
.variant =
|
||||
StoreReference::Specified{
|
||||
.scheme = *uriSchemes().begin(),
|
||||
.authority = path,
|
||||
},
|
||||
.params = getQueryParams(),
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue