Tahinli/forge
public0 watching
★ 0
| 1 | //! Rootless job sandbox. Each job runs in a libcontainer container, started by a helper process. |
| 2 | //! |
| 3 | //! The runner never calls libcontainer itself. libcontainer forks and clones, which is unsafe in |
| 4 | //! a multi-threaded tokio process, so the runner spawns `forge-runner __sandbox` as a |
| 5 | //! single-threaded child. That child reads a [`SandboxRequest`] on stdin and runs the job. See |
| 6 | //! `docs/ci-builtin-executor.md`. |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | use PathBuf; |
| 15 | |
| 16 | use ; |
| 17 | |
| 18 | use crateLimits; |
| 19 | use IdMap; |
| 20 | |
| 21 | pub use ; |
| 22 | pub use build_spec; |
| 23 | |
| 24 | /// What the runner sends the helper on stdin. It carries the secrets, so it is never written to |
| 25 | /// disk and never placed in argv. It deliberately has no `Debug` impl, so the env cannot leak |
| 26 | /// into a log line. |
| 27 | |
| 28 | |
| 29 | |
| 30 | |
| 31 | |
| 32 | |
| 33 | |
| 34 | |
| 35 | |
| 36 | |
| 37 | |
| 38 | |
| 39 | |
| 40 | |
| 41 | |
| 42 | |
| 43 | |
| 44 | |
| 45 | |
| 46 | |
| 47 | |
| 48 | |
| 49 | |
| 50 | |
| 51 | /// Errors from building or running a sandbox. |
| 52 | |
| 53 | |
| 54 | |
| 55 | |
| 56 | |
| 57 | |
| 58 | |
| 59 | |
| 60 | |
| 61 | |
| 62 | |
| 63 | |
| 64 | |
| 65 | |
| 66 | |
| 67 | |
| 68 | |
| 69 | |
| 70 | |
| 71 | |
| 72 |