Edgar Lee
7ce58c31ba
Plumb op metadata to recreate failed ops with gateway exec
...
Signed-off-by: Edgar Lee <edgarl@netflix.com >
2020-11-13 22:05:13 -08:00
Tonis Tiigi
e86356ddf8
solver: add input preprocess capability
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-11-03 14:49:44 -08:00
Tonis Tiigi
bdcee17437
executor: change mount to struct
...
Allows readonly passed cleanly.
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-11-02 22:20:51 -08:00
Tonis Tiigi
e3b05289d8
add session injection to remote loading
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-11-02 22:20:44 -08:00
Tonis Tiigi
ecf070a027
exec: use platform specific default path
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-10-23 15:30:23 -07:00
Lu Jingxiao
5e7ae230b2
Add hostname specifying for building
...
Fix : #1301
Signed-off-by: Lu Jingxiao <lujingxiao@huawei.com >
2020-10-14 14:45:36 +08:00
Cory Bennett
095a919c95
remove unnecessary MountManager interface
...
Signed-off-by: Cory Bennett <cbennett@netflix.com >
2020-10-02 06:24:34 +00:00
Cory Bennett
3cc8aa0649
move ExecOps mounting logic into new package so logic can be reused from gateway exec
...
Signed-off-by: Cory Bennett <cbennett@netflix.com >
2020-09-15 07:01:42 +00:00
Cory Bennett
5e91dff4ed
fix error handling for exec when container fails to start
...
update run/exec tests for stdin and expected failures
move common tests for runc and container to shared tests package
Signed-off-by: Cory Bennett <cbennett@netflix.com >
2020-07-10 22:06:42 +00:00
Cory Bennett
6d58121c11
Update Executor interface for Run and Exec
...
Signed-off-by: Cory Bennett <cbennett@netflix.com >
2020-07-09 23:40:36 +00:00
Tonis Tiigi
2e9987ad16
session: track sessions with a group construct
...
Avoid hidden session passing and allow one session to drop when
multiple builds share a vertex.
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-07-05 00:15:25 -07:00
Sebastiaan van Stijn
932c39505b
use containerd/sys to detect UserNamespaces
...
The implementation in libcontainer/system is quite complicated,
and we only use it to detect if user-namespaces are enabled.
In addition, the implementation in containerd uses a sync.Once,
so that detection (and reading/parsing `/proc/self/uid_map`) is
only performed once.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl >
2020-06-15 12:51:20 +02:00
Tonis Tiigi
f9e26128c0
exec: use qemu emulator automatically
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-06-07 22:08:52 -07:00
Tonis Tiigi
c78e875977
remove last instances of errors cause
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-04-24 11:25:53 -07:00
Tonis Tiigi
37b8832d00
upgrade errors checks to Is()
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-04-18 22:53:38 -07:00
Tonis Tiigi
6d907b6893
ops: fix deadlock on releasing shared mounts
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-02-03 18:47:42 -08:00
Tonis Tiigi
bf2dc85f80
ops: refactor cache mounts to have unit tests
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2020-02-03 15:00:22 -08:00
Tonis Tiigi
307bdc3c3d
exec: fix mount options on userns remapping
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-10-29 14:20:40 -07:00
Tonis Tiigi
a0dead0809
fix possible double release on mountable
...
Refactor the interface to avoid such issues in the future.
BuildKit own mounts are stateless and not affected but
a different mountable implementation could get confused.
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-08-16 08:03:16 -07:00
Tonis Tiigi
360a856527
ops: fix readwrite mounts it no output
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-08-08 22:07:30 -07:00
Tonis Tiigi
7b1bae7a42
solver: support no-cache for exec cache mounts
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-07-26 14:42:32 -07:00
Tibor Vass
fe8289063b
Merge pull request #1049 from tonistiigi/llb-validation
...
llbsolver: add more llb validation
2019-07-02 10:13:25 -07:00
Tonis Tiigi
5fc18fda78
llbsolver: add more llb validation
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-07-01 23:52:20 -07:00
Tonis Tiigi
0f1c7d0412
session: use errors cause
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-06-06 21:15:21 -07:00
Akihiro Suda
a2dcdf4277
Merge pull request #897 from tonistiigi/userns
...
userns remapping support base
2019-04-03 13:33:47 +09:00
Tonis Tiigi
15ef4e2b8a
dockerfile: allow content cache for rw mounts
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-04-02 19:40:30 -07:00
Tonis Tiigi
9b9ff6e4b5
revert userns mapping functions
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-04-02 18:26:06 -07:00
Tonis Tiigi
6921dbe0f6
snapshot: base for userns remapping
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-04-02 18:23:46 -07:00
Kunal Kushwaha
a2bbb5ff39
security entitlement support
...
Signed-off-by: Kunal Kushwaha <kushwaha_kunal_v7@lab.ntt.co.jp >
2019-03-27 13:57:03 +09:00
Tonis Tiigi
4ffd79735b
fileop: connect with contenthash
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-03-15 16:31:00 -07:00
Tonis Tiigi
81a5fa5a2e
llbsolver: fileop implementation
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-03-15 16:22:35 -07:00
Tonis Tiigi
6d859fc9b0
llbsolver: fix selectors dedupe
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-03-05 17:59:13 -08:00
Tonis Tiigi
f472cb193f
exec: fix platform value in cache key
...
Use vertex platform instead of the current system one. This shouldn't break any cache unless qemu was used. Even when qemu was used the issue would not cause any cache collisions because the base images for run were scoped by platform, but better to stop using invalid data for cache key calculation.
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-02-28 11:17:10 -08:00
Tonis Tiigi
b521aae3ea
dockerfile: allow setting file mode/uid for secrets
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-01-03 11:13:40 -08:00
Tonis Tiigi
2529762ae7
dockerfile: allow setting file mode/uid for ssh socket
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2019-01-03 11:13:34 -08:00
Tibor Vass
c9b01072d0
solver: specify SSH key ID in error message when required key was not forwarded
...
Signed-off-by: Tibor Vass <tibor@docker.com >
2018-10-05 22:50:07 +00:00
Ian Campbell
720d8327e2
Push setting of default PATH down into the executor(s)
...
Setting the default `PATH` in the `llb.State` on the client side means it
depends on the `GOOS` of the buildkit client, rather than of the environment
where it will actually execute.
Instead defer this to execution time and insert the default PATH at that point
if one is not present. Doing this in solver/llbsolver/ops/exec covers all
executors and also avoids breaking the cache.
Client compatibility is handled via a new capability.
Fixes #604
Signed-off-by: Ian Campbell <ijc@docker.com >
2018-09-28 14:16:47 +01:00
John Howard
2de2c04c8e
Revendoring to move boltdb to bbolt
...
Signed-off-by: John Howard <jhoward@microsoft.com >
2018-09-18 11:18:08 -07:00
Tonis Tiigi
6888956557
sshforward: implement ssh socket forwarding
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-09-07 08:57:06 -07:00
Tonis Tiigi
130f5f5ab0
solver: net host with basic entitlements support
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-08-09 14:03:35 -07:00
Tonis Tiigi
4945fe758c
llbsolver: add support for extra host records
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-08-03 13:56:13 -07:00
Tonis Tiigi
57b96a0ee5
cache: add record type field to usage record
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-07-26 22:54:39 -07:00
Tonis Tiigi
08d324d0dd
exec: fix secret mounts for rootless
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-07-19 22:02:11 -07:00
Tonis Tiigi
2da2aff164
llbsolver: add secret mounts
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-07-19 22:02:05 -07:00
Tonis Tiigi
ccbf185006
llbsolver: allow sharing modes for cache mounts
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-06-19 15:57:20 -07:00
Tonis Tiigi
3c973bacfe
llbsolver: allow concurrent cache mount access
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-06-08 20:02:30 -07:00
Tonis Tiigi
6f569455d0
dockerfile: enable tmpfs mounts on run —mount
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-06-08 13:42:38 -07:00
Tonis Tiigi
596b03a8a0
llbsolver: allow tmpfs mounts
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-06-08 13:05:14 -07:00
Tonis Tiigi
479419abf2
llbsolver: don’t error on readonly scratch mount
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com >
2018-06-07 16:23:53 -07:00
Akihiro Suda
e2fc1a702d
Merge pull request #414 from tonistiigi/stdio-debug
...
exec: make stdio debugging optional
2018-05-26 06:59:04 +09:00