k3s/vendor/github.com/containerd/continuity
Jacob Blain Christen 618b0f98bf
registry mirror repository rewrites (#3064)
Support repository regex rewrite rules when fetching image content.

Example configuration:
```yaml
# /etc/rancher/k3s/registries.yaml
mirrors:
  "docker.io":
    endpoint:
    - "https://registry-1.docker.io/v2"
    rewrite:
      "^library/alpine$": "my-org/alpine"
```

This will instruct k3s containerd to fetch content for `alpine` images
from `docker.io/my-org/alpine` instead of the default
`docker.io/library/alpine` locations.

Signed-off-by: Jacob Blain Christen <jacob@rancher.com>
2021-03-15 16:17:27 -07:00
..
devices registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
driver registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
fs registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
pathdriver Update vendor 2019-01-11 21:58:27 -07:00
proto Update vendor 2019-01-11 21:58:27 -07:00
sysx registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
.gitignore Update vendor 2019-01-11 21:58:27 -07:00
.golangci.yml registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
.mailmap Update vendor 2019-01-11 21:58:27 -07:00
AUTHORS registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
context.go registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
digests.go registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
go.mod registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
go.sum registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
groups_unix.go registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
hardlinks_unix.go registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
hardlinks_windows.go Update vendor 2019-01-11 21:58:27 -07:00
hardlinks.go registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
ioutils.go Update vendor 2019-01-11 21:58:27 -07:00
LICENSE Update vendor 2019-09-27 16:54:32 -07:00
Makefile registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
manifest.go registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
README.md registry mirror repository rewrites (#3064) 2021-03-15 16:17:27 -07:00
resource_unix.go Update vendor 2019-01-11 21:58:27 -07:00
resource_windows.go Update vendor 2019-01-11 21:58:27 -07:00
resource.go Update vendor 2019-01-11 21:58:27 -07:00

continuity

GoDoc Build Status

A transport-agnostic, filesystem metadata manifest system

This project is a staging area for experiments in providing transport agnostic metadata storage.

Please see https://github.com/opencontainers/specs/issues/11 for more details.

Manifest Format

A continuity manifest encodes filesystem metadata in Protocol Buffers. Please refer to proto/manifest.proto.

Usage

Build:

$ make

Create a manifest (of this repo itself):

$ ./bin/continuity build . > /tmp/a.pb

Dump a manifest:

$ ./bin/continuity ls /tmp/a.pb
...
-rw-rw-r--      270 B   /.gitignore
-rw-rw-r--      88 B    /.mailmap
-rw-rw-r--      187 B   /.travis.yml
-rw-rw-r--      359 B   /AUTHORS
-rw-rw-r--      11 kB   /LICENSE
-rw-rw-r--      1.5 kB  /Makefile
...
-rw-rw-r--      986 B   /testutil_test.go
drwxrwxr-x      0 B     /version
-rw-rw-r--      478 B   /version/version.go

Verify a manifest:

$ ./bin/continuity verify . /tmp/a.pb

Break the directory and restore using the manifest:

$ chmod 777 Makefile
$ ./bin/continuity verify . /tmp/a.pb
2017/06/23 08:00:34 error verifying manifest: resource "/Makefile" has incorrect mode: -rwxrwxrwx != -rw-rw-r--
$ ./bin/continuity apply . /tmp/a.pb
$ stat -c %a Makefile
664
$ ./bin/continuity verify . /tmp/a.pb

Platforms

continuity primarily targets Linux. continuity may compile for and work on other operating systems, but those platforms are not tested.

Contribution Guide

Building Proto Package

If you change the proto file you will need to rebuild the generated Go with go generate.

$ go generate ./proto

Project details

continuity is a containerd sub-project, licensed under the Apache 2.0 license. As a containerd sub-project, you will find the:

information in our containerd/project repository.