Commit Graph

2515 Commits (59edca02f388b6bd13a93a7df868129738710092)

Author SHA1 Message Date
Paul "TBBle" Hampson 59edca02f3 Fix linter warning about comment mismatch
Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-31 02:49:39 +10:00
Paul "TBBle" Hampson 883c726bd5 Compile containerd worker on Windows
It's not fully-functional at this time, but it now compiles, which means
we are getting nearer to the point where we can start enabling tests.

This will ensure that it _stays_ compilable over time.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-31 02:49:39 +10:00
Paul "TBBle" Hampson 1527525110 Unify OCI Spec generation across all host platforms
There's only a couple of things that are host-platform limited, i.e.,
security and process modes.

Everything else is specific to a target-platform. We can tell if we're
targeting a Linux platform, either on Linux or LCOW, by the presence of
the Linux key in the generated spec.

This doesn't introduce support for LCOW, as we'd need to plumb that down
from the caller. It will probably also need massaging to work with LCOW,
as some of the setup code here is probably incorrect for LCOW, e.g.,
the bind-mounts list may be incorrect.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-31 02:49:23 +10:00
Tõnis Tiigi 7b6dbdb715
Merge pull request #1615 from thaJeztah/update_deps
vendor: update opentracing-go v1.2.0, go-stdlib v1.0.0
2020-07-30 09:17:37 -07:00
Tõnis Tiigi 86d5a6a737
Merge pull request #1610 from TBBle/allow_equal_time_for_cache_entries
Ensure that time has passed between foo0 and foo1
2020-07-30 09:16:43 -07:00
Tõnis Tiigi 5c4fe66e97
Merge pull request #1618 from TBBle/clarify_gateway_test_as_a_build_test
Clarify the gateway 'test' as a build-test
2020-07-30 09:16:18 -07:00
Tõnis Tiigi bc84c830cb
Merge pull request #1617 from thaJeztah/remove_unused_context
executor/oci.GetUser(): remove unused context
2020-07-30 09:15:41 -07:00
Paul "TBBle" Hampson 3132f4d0ed Clarify the gateway 'test' as a build-test
It also doesn't need dockerd added to its container when it builds.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-30 23:12:29 +10:00
Sebastiaan van Stijn f26452a847
executor/oci.GetUser(): remove unused context
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-07-30 11:31:03 +02:00
Sebastiaan van Stijn 844c40a4de
vendor: update opentracing-go v1.2.0, go-stdlib v1.0.0
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-07-30 11:16:27 +02:00
Akihiro Suda 547db0f588
Merge pull request #1614 from tonistiigi/transport-tracing
resolver: enable tracing on default transport
2020-07-30 16:16:19 +09:00
Tonis Tiigi cdf424f677 resolver: enable tracing on default transport
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-29 23:19:52 -07:00
Paul "TBBle" Hampson f4393eaa31 Ensure that time has passed between foo0 and foo1
On Windows, the resolution of time.Now() can be surprisingly low: 15ms
according to the comments in the source of time.Now().

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-30 03:21:30 +10:00
Akihiro Suda 594ebbfac0
Merge pull request #1601 from tonistiigi/insecure-fix
push: reenable setting insecure exporter opt
2020-07-29 13:55:36 +09:00
Akihiro Suda 4d27bf48d1
Merge pull request #1612 from tonistiigi/deploy-cache
hack: use caching for master deploy
2020-07-29 13:55:08 +09:00
Akihiro Suda 251f40343f
Merge pull request #1611 from tonistiigi/update-containerd-0728
update containerd vendor and add 1.4-beta2 testing
2020-07-29 12:39:50 +09:00
Tonis Tiigi 70c2ab7f4d hack: use caching for master deploy
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-28 19:59:17 -07:00
Tonis Tiigi 942c39adfd add testing for containerd 1.4-beta2
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-28 18:13:15 -07:00
Tonis Tiigi 53b2f321e8 vendor: update containerd to eb6354a11
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-28 17:48:03 -07:00
Tõnis Tiigi 995ae310c7
Merge pull request #1607 from TBBle/fix_integration_test_build_on_windows
Fix test failures in unit tests on Windows
2020-07-28 12:00:55 -07:00
Paul "TBBle" Hampson 6c824d68f1 Use filesystem-supplied modes for checksumming content
The existing code was spuriously failing unit tests, because it was
stripping non-permission bits off the file mode.

On examination, the behaviour was inherited from similar code in
moby/moby, which was intended to affect the resulting filemodes inside
a Linux-based container built from Windows. However, this code path does
have that effect in BuildKit as we are only calculating checksums here.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-29 02:50:24 +10:00
Paul "TBBle" Hampson 46995ec794 Don't silently ignore failed wildcard expansion
This was letting mount-related errors slip by, and instead returning
an empty hash.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-29 02:50:20 +10:00
Paul "TBBle" Hampson b126501d78 Provide the known default PATH to the llbtest test
The existing test fails because the Windows default PATH (as far as LLB
knows) is empty. See the system.DefaultPathEnv comments.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 18:07:20 +10:00
Paul "TBBle" Hampson 9fd4d731d6 Fix oci.hasPrefix to operate correctly on Windows
Due to use of filepath.Clean(), on Windows we end up operating on the
paths in Windows-slashed form, even if the inputs were Unix-slashed.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 18:07:20 +10:00
Paul "TBBle" Hampson 13bf35d640 Run all the hasPrefix test-cases, even if one fails
This makes it easier to see what's gone wrong if they start failing.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 18:07:20 +10: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
Paul "TBBle" Hampson e48eaf9619 Log HostComputeNamespace name instead of the whole object
Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 18:07:20 +10:00
Paul "TBBle" Hampson 0c9d862645 Fix undefined variable in Windows-specific test
Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 18:07:20 +10:00
Paul "TBBle" Hampson b5e6d54910 Add errors-on-non-Linux ToRootless implementation
`go test` complains about this tree because the package ends up with no
symbols on non-Linux platforms, e.g., Windows, even though this API is
never be called on non-Linux platforms, according to the compiler.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 18:07:20 +10:00
Paul "TBBle" Hampson 5e3e18a72d Use OS-agnostic os.SameFile instead of inode comparision
This fixes the build of this test under Windows.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 13:50:48 +10:00
Paul "TBBle" Hampson f617b0828a Fix testutil/integration build on Windows
Although we don't run any integration tests on Windows at this time,
this does mean that the SKIP_INTEGRATION_TESTS env-var works, so we can
run a wider range of non-integration tests without spurious failures.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 13:50:48 +10:00
Tõnis Tiigi 3ac3a61321
Merge pull request #1604 from AkihiroSuda/update-doc-20200717
update docs
2020-07-27 15:15:50 -07:00
Tõnis Tiigi fe59e20f40
Merge pull request #1606 from TBBle/windows-CI-on-GitHub_Actions
Add initial GitHub Actions-based Windows CI
2020-07-27 08:58:38 -07:00
Paul "TBBle" Hampson 81595fe320 Add initial GitHub Actions-based Windows CI
Only a few tests are able to be run, because the integration test
support code fails to compile on Windows, taking effect before the
SKIP_INTEGRATION_TESTS env-var is handled.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-28 00:27:13 +10:00
Akihiro Suda d73640f7a1
Merge pull request #1595 from tonistiigi/shfmt
hack: add shfmt
2020-07-27 18:28:06 +09:00
Akihiro Suda 3691733e70
Merge pull request #1605 from tonistiigi/update-fsutil
vendor: update fsutil to c3ed55f3b4
2020-07-27 16:11:25 +09:00
Tonis Tiigi 846142df61 push: reenable setting insecure exporter opt
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-26 23:27:19 -07:00
Tonis Tiigi dc95525191 vendor: update fsutil to c3ed55f3b4
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-26 23:25:00 -07:00
Akihiro Suda 1957461428
README.md: add HLB, Earthfile, and Cargo Wharf
Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-07-27 15:04:11 +09:00
Akihiro Suda 444d506251
docs/rootless.md: drop support for Debian 9 and Fedora 30
Debian 9 has reached EOL on 2020-07-06: https://wiki.debian.org/DebianReleases
Fedora 30 has reached EOL on 2020-05-26: https://fedoraproject.org/wiki/End_of_life

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-07-27 14:34:56 +09:00
Akihiro Suda f22f2fc103
README.md: drop cgroup v2 notes
cgroup v2 is supported since runc v1.0.0-rc91 (will be included in
BuildKit since v0.7.2)

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>
2020-07-27 14:31:42 +09:00
Tonis Tiigi 67044875c4 resolver: allow setting both insecure tls and http
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-26 18:29:45 -07:00
Akihiro Suda e2260891a3
Merge pull request #1565 from AkihiroSuda/daemonless-show-log
buildctl-daemonless.sh: show log on "could not connect to ..."
2020-07-25 18:30:33 +09:00
Tonis Tiigi 8c55320f45 hack: add shfmt
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-07-24 21:17:54 -07:00
Tõnis Tiigi 866c12f9d2
Merge pull request #1593 from TBBle/locally_shortcut_ro_bind_mounts_on_windows
Locally shortcut read-only bind mounts on Windows
2020-07-24 20:05:39 -07:00
Paul "TBBle" Hampson f9b8fc64b1 Give a name to the only mount we care about
Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-24 20:40:46 +10:00
Paul "TBBle" Hampson 4e69b50469 Shortcut read-only bind-mounts in Windows, like non-Windows
Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-24 20:36:39 +10:00
Akihiro Suda 11a8e7216a
Merge pull request #1590 from tonistiigi/buffer-write
integration: lock buffer for concurrent writes
2020-07-24 16:17:47 +09:00