mirror of
https://github.com/NixOS/nix
synced 2025-06-25 06:31:14 +02:00
Remove buildUser
from DerivationBuilder
The use of a `buildUser` is an implementation detail of some types of sandboxes that shouldn't exposed.
This commit is contained in:
parent
ed3e2a71ea
commit
69914e4b3c
3 changed files with 7 additions and 7 deletions
|
@ -655,8 +655,8 @@ Goal::Co DerivationBuildingGoal::tryToBuild()
|
||||||
builder->startBuilder();
|
builder->startBuilder();
|
||||||
|
|
||||||
} catch (BuildError & e) {
|
} catch (BuildError & e) {
|
||||||
|
builder.reset();
|
||||||
outputLocks.unlock();
|
outputLocks.unlock();
|
||||||
builder->buildUser.reset();
|
|
||||||
worker.permanentFailure = true;
|
worker.permanentFailure = true;
|
||||||
co_return done(BuildResult::InputRejected, {}, std::move(e));
|
co_return done(BuildResult::InputRejected, {}, std::move(e));
|
||||||
}
|
}
|
||||||
|
|
|
@ -106,6 +106,11 @@ public:
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
|
/**
|
||||||
|
* User selected for running the builder.
|
||||||
|
*/
|
||||||
|
std::unique_ptr<UserLock> buildUser;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The cgroup of the builder, if any.
|
* The cgroup of the builder, if any.
|
||||||
*/
|
*/
|
||||||
|
@ -264,7 +269,7 @@ public:
|
||||||
/**
|
/**
|
||||||
* Start building a derivation.
|
* Start building a derivation.
|
||||||
*/
|
*/
|
||||||
void startBuilder() override;;
|
void startBuilder() override;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Tear down build environment after the builder exits (either on
|
* Tear down build environment after the builder exits (either on
|
||||||
|
|
|
@ -138,11 +138,6 @@ struct DerivationBuilderCallbacks
|
||||||
*/
|
*/
|
||||||
struct DerivationBuilder : RestrictionContext
|
struct DerivationBuilder : RestrictionContext
|
||||||
{
|
{
|
||||||
/**
|
|
||||||
* User selected for running the builder.
|
|
||||||
*/
|
|
||||||
std::unique_ptr<UserLock> buildUser;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The process ID of the builder.
|
* The process ID of the builder.
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue