Commit Graph

5537 Commits

Author SHA1 Message Date
Ian Campbell
3590c786bd Bump yml to pickup containerd v1.0.0
Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-05 16:39:05 +00:00
Dave Protasowski
2d6f4c5484 Allow vpnkit executable path to be specified
Signed-off-by: Steve Hiehn <shiehn@pivotal.io>
Signed-off-by: Dave Protasowski <dprotaso@gmail.com>
2017-12-05 10:06:58 -05:00
Steve Hiehn
ec45349638 Register vpnkit publish port clean up function as a logrus.ExitHandler
Signed-off-by: Dave Protasowski <dprotaso@gmail.com>
2017-12-05 10:05:23 -05:00
Dave Protasowski
c9b4f8306a Ensure VPNKit process is properly killed when errors occur
The log.Fatal* calls will leak the vpnkit process since
defer functions are not invoked when os.Exit(int) is invoked

We register an ExitHandler with logrus - that'll be invoke when
log.Fatal* is called

Signed-off-by: Steve Hiehn <shiehn@pivotal.io>
Signed-off-by: Dave Protasowski <dprotaso@gmail.com>
2017-12-05 09:48:09 -05:00
Rolf Neugebauer
c7d9418500
Merge pull request #2795 from rn/patch
kernel: Add NVDIMM size patch to 4.14.x
2017-12-05 13:42:10 +00:00
Rolf Neugebauer
5eee692887 kernel: Add NVDIMM size patch to 4.14.x
This change hasn't made it upstream but seems to be required
for LCOW to work.

Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
2017-12-05 10:32:33 +00:00
Ian Campbell
2561827100 Bump packages to new alpine w/ containerd v1.0.0
Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-05 09:55:32 +00:00
Ian Campbell
206bb92bbe alpine: Bump to containerd v1.0.0
https://github.com/containerd/containerd/releases/tag/v1.0.0

Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-05 09:54:47 +00:00
David Manouchehri
e9bc7353e6
As requested by @justincormack (https://github.com/linuxkit/linuxkit/pull/2784#issuecomment-349064467).
Signed-off-by: David Manouchehri <david.manouchehri@riseup.net>
2017-12-04 13:55:17 -05:00
Justin Cormack
dcff2008cd
Merge pull request #2789 from estesp/subreaper_ctrd-1.0rc0
remove subreaper config item
2017-12-04 18:49:33 +00:00
David Manouchehri
bc43735543
As requested by @ijc (https://github.com/linuxkit/linuxkit/pull/2784#pullrequestreview-80464126).
Signed-off-by: David Manouchehri <david.manouchehri@riseup.net>
2017-12-04 13:36:31 -05:00
Ian Campbell
edb6b4f7e1
Merge pull request #2792 from ijc/linuxkit-pkg-depend-images
Add dependent images to build.yml
2017-12-04 17:05:39 +00:00
Phil Estes
42014e361f
remove subreaper config item
containerd v1.0.0-rc.0 changed the subreaper config entry to the
negative given subreaper "on" is the default. However, linuxkit
does not need to change the default subreaper setting so removing
the now invalid config line.

Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com>
2017-12-04 09:23:22 -05:00
Ian Campbell
ce639e8080 linuxkit: implement docker image dependencies for pkg build.
This allows the `linuxkit/kubernetes` "image-cache" packages to use a standard
`linuxkit pkg build` based flow rather than requiring surrounding scaffolding.

Fixes #2766. Compared with the original (actually, the second) proposal made in
issue #2766, the field is `docker-images` rather than `images` to allow for
future inclusion of e.g. `containerd-images`.

Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-04 14:14:45 +00:00
Ian Campbell
98d46945d1 linuxkit: Use docker image «foo» consistently
In preference to the `docker «foo»` shortcut/aliases.

Better to be more specific.

Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-04 12:12:41 +00:00
Ian Campbell
8eed6a4b38 linuxkit: Rename Pkg.pkgPath to Pkg.path
Previous name a bit stuttery.

Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-04 12:12:41 +00:00
Justin Cormack
090abf3254
Merge pull request #2790 from justincormack/vbox
Add VirtualBox support to linuxkit run
2017-12-02 11:01:51 +00:00
Justin Cormack
3251f67015 Add VirtualBox support to linuxkit run
You can use `linuxkit run vbox ...` to run using Oracle VirtualBox.
ISO or raw should be supported, and you can specify EFI.

Some more options may be useful in future.

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
2017-12-01 21:48:21 +00:00
Rolf Neugebauer
00aaf428d9
Merge pull request #2788 from rn/kern
Update kernel to 4.14.3/4.9.66/4.4.103 and remove 4.13.x
2017-12-01 17:36:14 +00:00
Ian Campbell
f0059f03f4
Merge pull request #2787 from ijc/linuxkit-pkg-more-labels
Include tool version info in package/image labels
2017-12-01 15:30:31 +00:00
Rolf Neugebauer
2c2012cdee Update YAML files to latest kernels
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
2017-12-01 15:28:10 +00:00
Rolf Neugebauer
3ed38c59f4 kernel: Update to 4.14.3/4.9.66/4.4.103
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
2017-12-01 15:28:09 +00:00
Rolf Neugebauer
e7960ee0df kernel: Remove the 4.13.x kernel
4.13 has been EOLed with 4.13.16 being the last one.

Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
2017-12-01 15:28:09 +00:00
Ian Campbell
b0fbb5e4fd
Merge pull request #2786 from ijc/containerd-v1.0.0-rc.0
Bump to containerd-v1.0.0-rc.0
2017-12-01 15:08:37 +00:00
Ian Campbell
d03e6d65e2 linuxkit pkg: include linuxkit tool's version info in labels
Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-01 13:59:45 +00:00
Ian Campbell
13adecbc3e linuxkit: move version info to subpackage
Will avoid circular includes when I reference from pkglib too.

Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-01 13:55:43 +00:00
Ian Campbell
0dd863716d Bump yml
Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-01 13:40:16 +00:00
Ian Campbell
28e22e40bb Bump packages to new alpine w/ containerd v1.0.0-rc.0
Minor updates due to renamings in containerd.

Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-01 13:36:16 +00:00
Ian Campbell
e5caf00020 alpine: bump to containerd v1.0.0-rc.0
https://github.com/containerd/containerd/releases/tag/v1.0.0-rc.0

Minor build tweaks needed.

Signed-off-by: Ian Campbell <ijc@docker.com>
2017-12-01 13:21:08 +00:00
Rolf Neugebauer
d4451e4652
Merge pull request #2778 from zx2c4/wireguard-bump
wireguard: update to 0.0.20171122 to 0.0.20171127
2017-12-01 11:07:49 +00:00
Rolf Neugebauer
9a83407986
Merge pull request #2782 from ijc/hyperkit-net-fix
hyperkit: split network option into 3
2017-12-01 11:06:19 +00:00
David Manouchehri
80b54ed341
Reuse existing local Git repository (https://github.com/linuxkit/linuxkit/pull/2784#pullrequestreview-80121346).
Signed-off-by: David Manouchehri <david.manouchehri@riseup.net>
2017-11-30 14:12:41 -05:00
David Manouchehri
b262675c91
Switch to ${HOME} (https://github.com/linuxkit/linuxkit/pull/2784#pullrequestreview-80242701).
Signed-off-by: David Manouchehri <david.manouchehri@riseup.net>
2017-11-30 13:23:04 -05:00
David Manouchehri
899d62352e
Improve vagrant up time by skipping (possibly) unneeded updates.
Signed-off-by: David Manouchehri <david.manouchehri@riseup.net>
2017-11-29 21:58:18 -05:00
David Manouchehri
bb73dab8d3
Added initial Vagrant support.
Signed-off-by: David Manouchehri <david.manouchehri@riseup.net>
2017-11-29 21:46:20 -05:00
Justin Cormack
390e8d3cb2
Merge pull request #2780 from justincormack/ena
Add support for newer AWS networking types
2017-11-29 16:15:49 +00:00
Ian Campbell
0d9de644b8 hyperkit: split network option into 3
vpnkit mode has one or two arguments (eth socket and port control socket).

If splitting into only 2 then
    vpnkit,vpnkit-state/eth.sock,vpnkit-state/port.sock
becomes
    2: vpnkit
    1: vpnkit-state/eth.sock,vpnkit-state/port.sock
rather than
    0: vpnkit
    1: vpnkit-state/eth.sock
    2: vpnkit-state/port.sock
as desired.

Signed-off-by: Ian Campbell <ijc@docker.com>
2017-11-29 15:12:30 +00:00
Justin Cormack
6e9b1bb09a Add support for newer AWS networking types
- ENA networking is what the very new (and bare metal) machines have
- sriov "simple" mode is Intel VF passthrough

I reflect the underlying APIs, which is bool for ENA and a string
for sriov even though there is currently only one valid sriov option...

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
2017-11-29 14:46:48 +00:00
Rolf Neugebauer
e4fcf70cdd
Merge pull request #2775 from arm64b/master-Makefile-fixing
Makefile: Fix binaries generation issue when 'docker run' failed
2017-11-29 12:00:36 +00:00
Justin Cormack
964eb5f9d7
Merge pull request #2779 from justincormack/bind-resolv-nginx
Bind mount /etc/resolv.conf into nginx container
2017-11-29 11:33:05 +00:00
Dennis Chen
a4cc18622c Makefile: Fix binaries generation issue when 'docker build' failed
Currently we will always create a temp tar file even the 'docker run'
failed for some reason,e.g, the docker daemon doesn't run. As a result,
we'll get the 2nd error even we've fixed 'docker run' failure.

Signed-off-by: Dennis Chen <dennis.chen@arm.com>
2017-11-29 01:46:34 +00:00
Justin Cormack
3bc4766f39 Bind mount /etc/resolv.conf into nginx container
Signed-off-by: Justin Cormack <justin.cormack@docker.com>
2017-11-28 17:18:17 +00:00
Justin Cormack
c6fad9f76b
Merge pull request #2777 from ijc/linuxkit-pkg-label-in-build.yml
linuxkit pkg: Add `config` field to `build.yml`
2017-11-28 14:59:38 +00:00
Ian Campbell
fd9242d5ef Bump yml
Signed-off-by: Ian Campbell <ijc@docker.com>
2017-11-28 13:32:04 +00:00
Ian Campbell
1f6c1a59ca linuxkit pkg: Add config field to build.yml
This is a `moby.ImageConfig` struct which is marshalled into JSON and added as
the `org.mobyproject.config` label on the built image.

Convert `pkg/sysctl` as PoC.

Signed-off-by: Ian Campbell <ijc@docker.com>
2017-11-28 12:01:39 +00:00
Jason A. Donenfeld
62b5917526 wireguard: update to 0.0.20171122 to 0.0.20171127
This is a double bump.

Changes 0.0.20171122:

  * chacha20poly1305: fast primitives from Andy Polyakov

  Samuel Neves and I have spent considerable time and headaches porting,
  reworking, and partially rewriting Andy's optimized implementations of
  ChaCha20 and Poly1305. We now support the following:

  On x86_64:
    - Poly1305: integer unit
    - ChaCha20: SSSE3
    - HChaCha20: SSSE3
    - Poly1305: AVX
    - ChaCha20: AVX2
    - Poly1305: AVX2
    - ChaCha20: AVX512
    - Poly1305: AVX512

  On ARM:
    - Poly1305: integer unit
    - ChaCha20: NEON
    - Poly1305: NEON

  On ARM64:
    - Poly1305: integer unit
    - ChaCha20: NEON
    - Poly1305: NEON

  On MIPS64:
    - Poly1305: integer unit

  All others:
    - ChaCha20: generic C
    - Poly1305: generic C

  This is a pretty substantial amount of new handrolled assembly. It will
  perhaps MURDER KITTENS, so please tread lightly with this snapshot and adjust
  expectations accordingly. I'm looking forward to quickly fixing any issues
  folks find while testing.

  Performance-wise, this should see increases all around. The biggest speedups
  will be on ARM and ARM64, but x86_64 and MIPS64 should also see modest speed
  improvements too, especially on Skylake systems supporting AVX512.

  * chacha20poly1305: add more test vectors, some of which are weird

  Test vectors are pretty important, so we added more to catch odd edge cases
  using the following butcher's code:

    from cryptography.hazmat.primitives.ciphers.aead import ChaCha20Poly1305
    import os

    def encode_blob(blob):
        a = ""
        for i in blob:
            a += "\\x" + hex(i)[2:]
        return a

    enc = [ ]
    dec = [ ]

    def make_vector(plen, adlen):
        key = os.urandom(32)
        nonce = os.urandom(8)
        p = os.urandom(plen)
        ad = os.urandom(adlen)
        c = ChaCha20Poly1305(key).encrypt(nonce=bytes(4) + nonce, data=p, associated_data=ad)

        out = "{\n"
        out += "\t.key\t= \"" + encode_blob(key) + "\",\n"
        out += "\t.nonce\t= \"" + encode_blob(nonce) + "\",\n"
        out += "\t.assoc\t= \"" + encode_blob(ad) + "\",\n"
        out += "\t.alen\t= " + str(len(ad)) + ",\n"
        out += "\t.input\t= \"" + encode_blob(p) + "\",\n"
        out += "\t.ilen\t= " + str(len(p)) + ",\n"
        out += "\t.result\t= \"" + encode_blob(c) + "\"\n"
        out += "}"
        enc.append(out)

        out = "{\n"
        out += "\t.key\t= \"" + encode_blob(key) + "\",\n"
        out += "\t.nonce\t= \"" + encode_blob(nonce) + "\",\n"
        out += "\t.assoc\t= \"" + encode_blob(ad) + "\",\n"
        out += "\t.alen\t= " + str(len(ad)) + ",\n"
        out += "\t.input\t= \"" + encode_blob(c) + "\",\n"
        out += "\t.ilen\t= " + str(len(c)) + ",\n"
        out += "\t.result\t= \"" + encode_blob(p) + "\"\n"
        out += "}"
        dec.append(out)

    make_vector(0, 0)
    make_vector(0, 8)
    make_vector(1, 8)
    make_vector(1, 0)
    make_vector(129, 7)
    make_vector(256, 0)
    make_vector(512, 0)
    make_vector(513, 9)
    make_vector(1024, 16)
    make_vector(1933, 7)
    make_vector(2011, 63)

    print("======== encryption vectors ========")
    print(", ".join(enc))

    print("\n\n\n======== decryption vectors ========")
    print(", ".join(dec))

  * wg-quick: document localhost exception and v6 rule

  Probably a "kill switch" wants this too:
     -m addrtype ! --dst-type LOCAL
  so that basic local services can continue to work.

  * selftest: allowedips: randomized test mutex update
  * allowedips: do not write out of bounds
  * device: uninitialize socket first in destruction
  * tools: tighten up strtoul parsing

  Small fixups.

  * qemu: update kernel
  * qemu: use unprefixed strip when not cross-compiling

  Fedora/Redhat doesn't ship with a prefixed strip, and we don't need
  to use it anyway when we're not cross compiling, so don't.

  * compat: 3.16.50 got proper rt6_get_cookie
  * compat: stable finally backported fix
  * compat: new kernels have netlink fixes
  * compat: fix compilation with PaX

  Usual set of compatibility updates.

  * curve25519-neon: compile in thumb mode

  In thumb mode, it's not possible to use sp as an operand of and, so
  we have to muck around with r3 as a scratch register.

  * socket: only free socket after successful creation of new

  When an interface is down, the socket port can change freely. A socket
  will be allocated when the interface comes up, and if a socket can't be
  allocated, the interface doesn't come up.

  However, a socket port can change while the interface is up. In this
  case, if a new socket with a new port cannot be allocated, it's
  important to keep the interface in a consistent state. The choices are
  either to bring down the interface or to preserve the old socket. This
  patch implements the latter.

  * global: switch from timeval to timespec

  This gets us nanoseconds instead of microseconds, which is better, and
  we can do this pretty much without freaking out existing userspace,
  which doesn't actually make use of the nano/microseconds field. The below
  test program shows that this won't break existing sizes:

    zx2c4@thinkpad ~ $ cat a.c
    void main()
    {
        puts(sizeof(struct timeval) == sizeof(struct timespec) ?
          "success" : "failure");
    }
    zx2c4@thinkpad ~ $ gcc a.c -m64 && ./a.out
    success
    zx2c4@thinkpad ~ $ gcc a.c -m32 && ./a.out
    success

Changes 0.0.20171127:

  * compat: support timespec64 on old kernels
  * compat: support AVX512BW+VL by lying
  * compat: fix typo and ranges
  * compat: support 4.15's netlink and barrier changes
  * poly1305-avx512: requires AVX512F+VL+BW

  Numerous compat fixes which should keep us supporting 3.10-4.15-rc1.

  * blake2s: AVX512F+VL implementation
  * blake2s: tweak avx512 code
  * blake2s: hmac space optimization

  Another terrific submission from Samuel Neves: we now have an implementation
  of Blake2s using AVX512, which is extremely fast.

  * allowedips: optimize
  * allowedips: simplify
  * chacha20: directly assign constant and initial state

  Small performance tweaks.

  * tools: fix removing preshared keys
  * qemu: use netfilter.org https site
  * qemu: take shared lock for untarring

  Small bug fixes.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2017-11-27 20:55:31 +01:00
Rolf Neugebauer
3cd02db567
Merge pull request #2774 from rn/kern-up
Update kernels
2017-11-27 11:42:38 +00:00
Rolf Neugebauer
bec7456d9b Update YAML files with latests kernels
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
2017-11-24 15:13:09 +00:00
Rolf Neugebauer
43b2caf69e kernel: Update to 4.4.102/4.9.65/4.13.16/4.14.2
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
2017-11-24 13:55:21 +00:00
Rolf Neugebauer
c6721e5343 kernel: Update to 4.4.101
Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
2017-11-24 13:55:21 +00:00