Akihiro Suda
be8ab28a0a
Merge pull request #2081 from tonistiigi/local-differ-none
...
Allow none differ on local source to avoid false Dockerfile matches
2021-07-01 09:42:24 +09:00
Cory Bennett
b1d441b175
[ #2112 ] progress.FromContext returns a writer factory
...
this allows progress.Controller to manage the writer lifecycle
Signed-off-by: Cory Bennett <cbennett@netflix.com>
2021-06-28 18:58:29 +00:00
Cory Bennett
1da8b671c4
[ #2112 ] progress.Controller should own the progress.Writer to prevent leaks
...
Signed-off-by: Cory Bennett <cbennett@netflix.com>
2021-06-28 18:56:45 +00:00
Tonis Tiigi
a7b155e30c
llb: don't allow content diff for now
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2021-06-11 21:15:10 -07:00
Tonis Tiigi
baa4fcdb0f
add differ support for local source
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2021-06-11 21:15:07 -07:00
Tõnis Tiigi
03af083def
Merge pull request #2144 from thaJeztah/bump_golang
...
update to go 1.16
2021-06-08 10:30:33 -07:00
Sebastiaan van Stijn
22dd74ae93
update to go 1.16
...
This updates all occurrences of Go 1.13 to Go 1.16; also updated
the code that's used to redact credentials in URLs to use the Go
implementation.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2021-06-02 00:31:57 +02:00
Tonis Tiigi
3bdb6b5159
git: support subdir component
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2021-05-19 22:13:04 -07:00
Alex Couture-Beil
5d2fd7eb45
Redact credentials from URLs before returning errors
...
this is to prevent errors such as
failed to fetch remote https://user:password@github.com/user/private-repo-failure.git : exit status 128
from leaking the password; now it will be displayed like:
failed to fetch remote https://user:xxxxx@non-existant-host/user/private-repo.git : exit status 128
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2021-04-28 10:39:15 -07:00
Pierre Fenoll
a471427331
Fix potential crash on nil value
...
Signed-off-by: Pierre Fenoll <pierrefenoll@gmail.com>
2021-04-15 15:01:02 +02:00
Tonis Tiigi
5bf64293f8
git: set token only for main remote access
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2021-02-19 00:25:35 -08:00
Alex Couture-Beil
3a5bdf0710
Move prefix check to isGitTransport
...
- rename IsSSHTransport to IsImplicitSSHTransport
- add testing for NewGitIdentifier
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2021-01-04 11:09:56 -08:00
Alex Couture-Beil
3fa063dcf3
move ssh regexp test to common location
...
- include testing
- improve hostname checking
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-12-10 17:10:38 -08:00
Alex Couture-Beil
23af9dcb86
require a username for git over ssh
...
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-12-10 17:10:38 -08:00
Alex Couture-Beil
b64f992917
Allow any ssh-user while cloning from git
...
- this allows one to use a non-standard ssh username like repo@host
rather than assuming it must be git@host
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-12-10 17:10:38 -08:00
Tonis Tiigi
a6baa678ea
fix building from git url without a protocol
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-12-09 18:40:34 -08:00
Tonis Tiigi
e46cfab9fb
fix invalid cancellation errors on pull
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-12-01 00:27:31 -08:00
Alex Couture-Beil
985bd6e7fb
disable host key checking when none are given
...
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-11-12 19:26:24 -08:00
Alex Couture-Beil
92e89a3374
Fixes related to the PR
...
- back out changes to changing the git url
- fix gid
- ignore global ssh config option when specifying known hosts
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-11-12 17:32:29 -08:00
Alex Couture-Beil
486c5fd5c6
change ssh auth sock perms to 0700
...
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-11-11 08:20:33 -08:00
Alex Couture-Beil
f2c8eb177c
Support cloning from non-standard git repos
...
- fixes assumption that ssh git clones must be via the `git` user.
- allows passing the SSH_AUTH_SOCK from the client to GitSource
- allows passing a known_host entry for ssh
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-11-10 15:55:17 -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
Sebastiaan van Stijn
fbe1346912
replace github.com/docker/docker/pkg/locker with moby/locker v1.0.1
...
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-10-30 09:25:05 +01:00
Tonis Tiigi
6a3d6e983b
source: fix puller error caching on cancellation
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-10-27 13:21:49 -07:00
ktock
a9ba84fd5e
Limit size of additional label for avoiding preparation failure
...
In containerd, there is a size limit for label size (4096 chars).
If an image has many layers (> (4096-43)/72 > 55),
`containerd.io/snapshot/remote/stargz.layers` will hit the limit of
label size and the remote snapshot preparation will fail.
This commit fixes this by limiting the size of the label.
Signed-off-by: ktock <ktokunaga.mail@gmail.com>
2020-09-11 11:40:56 +09:00
ktock
c975424deb
Enable to use remote snapshots for refs
...
Signed-off-by: ktock <ktokunaga.mail@gmail.com>
2020-08-24 08:44:00 +09:00
Tonis Tiigi
f1cd79bf65
resolver: add better pooling and custom authenticator
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-08-13 17:27:11 -07:00
Erik Sipsma
1b30fd146b
cache: Remove ImageRef from DescHandlers
...
Signed-off-by: Erik Sipsma <erik@sipsma.dev>
2020-08-05 17:18:43 -07:00
Erik Sipsma
926ca1804c
pull: de-pointer non-optional platform field
...
Signed-off-by: Erik Sipsma <erik@sipsma.dev>
2020-08-05 17:18:43 -07:00
Erik Sipsma
55cbd19dec
Add support for lazily-pulled blobs in cache manager.
...
This allows the layers of images to only be pulled if/once they are actually
required.
Signed-off-by: Erik Sipsma <erik@sipsma.dev>
2020-08-05 17:18:43 -07:00
Paul "TBBle" Hampson
32a080f0f3
Skip source tests on Windows that depend on read-write bind-mounts
...
These were previously failing due to use of sh.exe on Windows, and with
that fixed, have been revealed to depend on bind-mounts.
Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 18:07:20 +10:00
Paul "TBBle" Hampson
31195373cf
Don't rely on sh being in the PATH on Windows for tests
...
Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 18:07:20 +10:00
Paul "TBBle" Hampson
b2d3473cba
Skip tests on Windows that attempt to bind-mount read-only
...
Containerd's mounter doesn't yet support bind-mounts on Windows.
BuildKit short-cuts this for read-write mounts, but not read-only
mounts.
Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 18:07:20 +10:00
Tonis Tiigi
c8190b1518
lint: enable golint
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-19 09:28:24 -07:00
Tonis Tiigi
05013a663b
pull: fix session updating on resolver
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-05 00:15:33 -07:00
Tonis Tiigi
214aa5dbcf
pull: allow separate sessions for different parts of pull
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-05 00:15:33 -07: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
Tonis Tiigi
49de675234
git: support for token authentication
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-06-16 17:00:06 -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
Vlad A. Ionescu
cd4a80c086
Add comment about the use of --force
...
Signed-off-by: Vlad A. Ionescu <vladaionescu@users.noreply.github.com>
2020-03-27 18:35:18 -07:00
Vlad A. Ionescu
4ce2075095
Add --force flag in git fetch command
...
Signed-off-by: Vlad A. Ionescu <vladaionescu@users.noreply.github.com>
2020-03-27 18:06:49 -07:00
Tonis Tiigi
2c3cf11fde
resolver: update to new registryhosts based config
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-03-05 19:56:43 -08:00
Edgar Lee
2edb431a0f
Allow previous solve results to be used in new solves
...
Signed-off-by: Edgar Lee <edgarl@netflix.com>
2020-01-23 11:02:40 -08:00
Tonis Tiigi
339d4b2fef
leaseutil: mark temporary leases with timestamps
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2019-10-16 10:35:50 -07:00
Tonis Tiigi
31a9aeea88
cache: add migration flow to new lease based format
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2019-10-16 10:35:49 -07:00
Tonis Tiigi
08194783e0
cache: update unit tests to new cache manager constructor
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2019-10-16 10:34:50 -07:00
Tonis Tiigi
6be136db6e
cleanup unused code
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2019-10-16 10:33:01 -07:00
Tonis Tiigi
a9209caa93
clean up temporary leases on startup after crash
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2019-10-16 10:32:57 -07:00
Tonis Tiigi
2d0f9d3cc0
add manifest/config to the lease
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2019-10-16 10:32:52 -07:00
Tonis Tiigi
688e2c2272
cache: update components to new lease based cache manager
...
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2019-10-16 10:32:04 -07:00