![]() |
Nix 2.36.0
Nix, the purely functional package manager; unstable internal interfaces
|
#include <local-settings.hh>
Public Types | |
| using | ExternalBuilders = std::vector<ExternalBuilder> |
| Public Types inherited from nix::Config | |
| using | Settings = std::map<std::string, SettingData> |
Public Member Functions | |
| GCSettings & | getGCSettings () |
| const GCSettings & | getGCSettings () const |
| const AutoAllocateUidSettings * | getAutoAllocateUidSettings () const |
| const AbsolutePath * | getDiffHook () const |
| const ExternalBuilder * | findExternalDerivationBuilderIfSupported (const BasicDerivation &drv) |
| Public Member Functions inherited from nix::Config | |
| Config (StringMap initials={}) | |
| bool | set (const std::string &name, const std::string &value) override |
| void | addSetting (AbstractSetting *setting) |
| void | getSettings (std::map< std::string, SettingInfo > &res, bool overriddenOnly=false) const override |
| void | resetOverridden () override |
| nlohmann::json | toJSON () override |
| std::string | toKeyValue (bool overriddenOnly=false) override |
| void | convertToArgs (Args &args, const std::string &category) override |
| Public Member Functions inherited from nix::AbstractConfig | |
| void | applyConfig (const std::string &contents, const std::string &path="<unknown>") |
| void | warnUnknownSettings () |
| void | reapplyUnknownSettings () |
Additional Inherited Members | |
| Protected Member Functions inherited from nix::AbstractConfig | |
| AbstractConfig (StringMap initials={}) | |
| Protected Attributes inherited from nix::AbstractConfig | |
| StringMap | unknownSettings |
Either about local store or local building
These are things that should not be part of the global settings, but should be per-local-store at a minimum. We expose them from settings with settings.getLocalSettings() for now, but we also have localStore.config->getLocalSettings() as a way to get them too. Even though both ways will actually draw from the same global variable, we would much prefer if you use the second one, because this will prepare the code base to making these actual, rather than pretend, per-store settings.
| const ExternalBuilder * nix::LocalSettings::findExternalDerivationBuilderIfSupported | ( | const BasicDerivation & | drv | ) |
Finds the first external derivation builder that supports this derivation, or else returns a null pointer.
|
inline |
Get AutoAllocateUidSettings if auto-allocate-uids is enabled.
|
inline |
Get the diff hook path if run-diff-hook is enabled.
|
inline |
Get the GC settings.
| Setting<std::set<std::filesystem::path> > nix::LocalSettings::allowedImpureHostPrefixes |
| Setting<bool> nix::LocalSettings::allowNewPrivileges |
| Setting<bool> nix::LocalSettings::allowSymlinkedStore |
| Setting<bool> nix::LocalSettings::autoAllocateUids |
| Setting<bool> nix::LocalSettings::autoOptimiseStore |
| Setting<unsigned int> nix::LocalSettings::buildCores |
| Setting<std::optional<AbsolutePath> > nix::LocalSettings::buildDir |
| Setting<bool> nix::LocalSettings::darwinLogSandboxViolations |
| Setting<bool> nix::LocalSettings::filterSyscalls |
| Setting<bool> nix::LocalSettings::fsyncMetadata |
| Setting<bool> nix::LocalSettings::fsyncStorePaths |
| Setting<Strings> nix::LocalSettings::hashedMirrors |
| Setting<size_t> nix::LocalSettings::narBufferSize |
| Setting<std::string> nix::LocalSettings::preBuildHook |
| Setting<bool> nix::LocalSettings::requireDropSupplementaryGroups |
| Setting<bool> nix::LocalSettings::runDiffHook |
| Setting<AbsolutePath> nix::LocalSettings::sandboxBuildDir |
| Setting<bool> nix::LocalSettings::sandboxFallback |
| Setting<PathsInChroot> nix::LocalSettings::sandboxPaths |
| Setting<std::string> nix::LocalSettings::sandboxShmSize |
| Setting<bool> nix::LocalSettings::syncBeforeRegistering |
| Setting<bool> nix::LocalSettings::useCgroups |