| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
| |
Calling _reset() instead of completely replacing the object fixes
element plugins that use a virtual directory object across Sandbox.run()
calls such as the compose plugin with integration commands.
|
|
|
|
| |
This reinitializes a CASBasedDirectory object from a directory digest.
|
| |
|
|
|
|
|
|
|
|
| |
To protect the local cache of buildbox-casd from corruption without the
use of FUSE, buildbox-casd has to run as a different user.
Use less restrictive umasks in the source determinism tests to allow
buildbox-casd to function when it is running as a separate user.
|
|
|
|
|
| |
This is set to True if buildbox-casd is installed with the set-uid bit
and thus, indicates whether buildbox-casd is running as a separate user.
|
|
|
|
|
|
|
|
|
|
|
| |
By default, Linux doesn't allow creating hardlinks to read-only files of
other users since Linux 3.6 (see /proc/sys/fs/protected_hardlinks).
This fixes staging when buildbox-casd is running as a separate user and
the traditional bubblewrap sandboxing backend is used. This combination
is not recommended, however, it's triggered in CI by docker images that
run buildbox-casd as a separate user and a few test cases that override
BST_FORCE_SANDBOX.
|
|
|
|
|
|
|
|
|
|
|
| |
This is necessary to allow using buildbox-run with userchroot in the
near future, since currently only the owner of the BuildStream process
can access the CASD socket, but the buildbox-casd binary will need to
be setuid' to another user.
This gets around this limitation by allowing the group to access a
symlink, which in turn should point to a directory owned by the CASD
user.
|
| |
|
|
|
|
|
|
| |
This also involves a number of changes to tests and other parts of the
codebase since they were hacking about wit API that shouldn't have
existed.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
This updates all dependencies on the project, which is mainly needed
by python3.8 but can be done independentely.
This also disables multiple false positive lint errors and disable a
new check that we don't need.
|
|
|
|
|
| |
Newer pylint versions detect and complain about unnecessary elif/else
after a continue/break/return clause. Let's remove them
|
|
|
|
|
| |
Newer version of pylint detect when a comprehension would not be needed.
Let's remove all the ones that are indeed extraneous
|
| |
|
| |
|
|
|
|
|
| |
The working directory must be specified relative to the input root,
i.e., the leading slash must be dropped.
|
|
|
|
| |
Sandbox implementations rely on this.
|
| |
|
| |
|
|
|
|
|
|
| |
Set the workspace plugin `__last_successful` attribute.
loader: Use empty string as default when last_successful is missing
|
| |
|
| |
|
|
|
|
|
| |
We don't have many of the `--track` options anymore, so we can remove
handling for them in parts of the code that don't need it.
|
| |
|
|
|
|
| |
This allows access by buildbox-casd running as different user.
|
| |
|
| |
|
|
|
|
|
|
|
| |
This allows access by buildbox-casd running as different user with a
suitable umask. As this is not generally safe in global temp directories
such as /tmp, make the `dir` parameter mandatory and add a note to the
documentation.
|
|
|
|
| |
This allows access by buildbox-casd running as different user.
|
| |
|
|
|
|
|
| |
It doesn't seem like we need to call GetCapabilities here, as we're not
querying anything. Remove the call to save some time.
|
| |
|
|
|
|
|
|
| |
Change _CASCacheUsageMonitor to hold a CASDChannel instead of
it's parent CASCache. This means that when in spawn mode, we don't need
to pickle the CASCache, only the CASDChannel.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Encapsulate the management of a connection to CASD, so we can hide the
details of how it happens. This will make it easier to port to Windows,
as we will have to take a different approach there.
Remove the _LimitedCASDProcessManagerProxy, as CASDChannel does
everything the child jobs will need.
Also make get_local_cas() public, since it is already used outside of
the CASCache class. Make get_cas() public to match.
|
|
|
|
|
|
|
| |
Elsewhere in cascache, cleaning up is called 'release_resources', so
follow that convention for consistency.
Also fix a case where self.process was not set to None in terminate().
|
|
|
|
|
|
|
|
|
|
| |
Make it easier to specialize handling of the buildbox-casd process on
Windows, by splitting it into it's own class. This allows us to
encapsulate some decisions, and decreases the complexity of the CASCache
class.
Take some of the complexity out of this file by splitting the
responsibility of managing the process out to another file.
|
|
|
|
|
|
| |
There was some duplicated functionality between `Stream._load()` and
`Stream._load_tracking()`, this is factored out and hopefully makes
the cognitive complexity a bit lower.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
These were caused by unhandled errors from plugins when calling
`Source.get_consistency()`. This doesn't really solve the problem,
since that interface is still used un-wrapped elsewhere, but it
enables removing `Element.__schedule_tracking()` and fixes a bug.
Ultimately we'd like to remove `Source.get_consistency()`, so this
isn't too long-term of a problem.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Just as with the previous commit, inspired by our code quality
linter. Poor practice from the previous function probably snuck in
here too.
|
|
|
|
|
| |
This is on suggestion of our code quality linter - it should make
understanding the pre-requisites of the function simpler.
|
| |
|
| |
|