Skip to content
This repository has been archived by the owner on May 26, 2023. It is now read-only.

Commit

Permalink
extend the oci client with list repositories and list tags functions
Browse files Browse the repository at this point in the history
  • Loading branch information
Tim Schrodi committed Apr 7, 2021
1 parent 61f4295 commit b8f7be9
Show file tree
Hide file tree
Showing 25 changed files with 1,263 additions and 19 deletions.
6 changes: 3 additions & 3 deletions docs/reference/components-cli_component-archive.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,21 @@


```
components-cli component-archive component-archive-path [ctf-path] [flags]
components-cli component-archive [component-archive-path] [ctf-path] [flags]
```

### Options

```
-a, --archive string path to the component archive directory
--component-name string name of the component
-c, --component-ref stringArray path to resources definition
-c, --component-ref stringArray path to component references definition
--component-version string version of the component
--format CAOutputFormat archive format of the component archive. Can be "tar" or "tgz" (default tar)
-h, --help help for component-archive
--repo-ctx string [OPTIONAL] repository context url for component to upload. The repository url will be automatically added to the repository contexts.
-r, --resources stringArray path to resources definition
-s, --sources stringArray path to resources definition
-s, --sources stringArray path to sources definition
--temp-dir string temporary directory where the component archive is build. Defaults to a os-specific temp dir
```

Expand Down
7 changes: 3 additions & 4 deletions docs/reference/components-cli_image-vector_add.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ resources:
2. The image is defined by another component so the image is added as label ("imagevector.gardener.cloud/images") to the "componentReference".

Images that are defined by other components can be specified
1. [DEPRECATED] when the image's repository matches the given "--component-prefixes"
1. when the image's repository matches the given "--component-prefixes"
2. the image is labeled with "imagevector.gardener.cloud/component-reference"

If the component reference is not yet defined it will be automatically added.
Expand Down Expand Up @@ -86,10 +86,10 @@ componentReferences:
</pre>

3. The image is a generic dependency where the actual images are defined by the overwrite.
A generic dependency image is not part of a component descriptors resource but will be added as label ("imagevector.gardener.cloud/images") to the component descriptor.
A generic dependency image is not part of a component descriptor's resource but will be added as label ("imagevector.gardener.cloud/images") to the component descriptor.

Generic dependencies can be defined by
1. [DEPRECATED] defined as "--generic-dependency=<image name>"
1. defined as "--generic-dependency=<image name>"
2. the label "imagevector.gardener.cloud/generic"

<pre>
Expand All @@ -113,7 +113,6 @@ component:
- name: hyperkube
repository: k8s.gcr.io/hyperkube
sourceRepository: github.com/kubernetes/kubernetes
tag: v0.10.0
targetVersion: '< 1.19'
</pre>

Expand Down
2 changes: 2 additions & 0 deletions docs/reference/components-cli_oci.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,6 @@

* [components-cli](components-cli.md) - components cli
* [components-cli oci pull](components-cli_oci_pull.md) - Pulls a oci artifact from a registry
* [components-cli oci repositories](components-cli_oci_repositories.md) - Lists all repositories of the registry
* [components-cli oci tags](components-cli_oci_tags.md) - Lists all tags of artifact reference

39 changes: 39 additions & 0 deletions docs/reference/components-cli_oci_repositories.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
## components-cli oci repositories

Lists all repositories of the registry

### Synopsis


repositories lists all known repositories of the registry.



```
components-cli oci repositories [registry host] [flags]
```

### Options

```
--allow-plain-http allows the fallback to http if the oci registry does not support https
--cc-config string path to the local concourse config file
-h, --help help for repositories
--registry-config string path to the dockerconfig.json with the oci registry authentication information
```

### Options inherited from parent commands

```
--cli logger runs as cli logger. enables cli logging
--dev enable development logging which result in console encoding, enabled stacktrace and enabled caller
--disable-caller disable the caller of logs (default true)
--disable-stacktrace disable the stacktrace of error logs (default true)
--disable-timestamp disable timestamp output (default true)
-v, --verbosity int number for the log level verbosity (default 1)
```

### SEE ALSO

* [components-cli oci](components-cli_oci.md) -

39 changes: 39 additions & 0 deletions docs/reference/components-cli_oci_tags.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
## components-cli oci tags

Lists all tags of artifact reference

### Synopsis


tags lists all tags for a specific artifact reference that is known by the registry.



```
components-cli oci tags [artifact reference] [flags]
```

### Options

```
--allow-plain-http allows the fallback to http if the oci registry does not support https
--cc-config string path to the local concourse config file
-h, --help help for tags
--registry-config string path to the dockerconfig.json with the oci registry authentication information
```

### Options inherited from parent commands

```
--cli logger runs as cli logger. enables cli logging
--dev enable development logging which result in console encoding, enabled stacktrace and enabled caller
--disable-caller disable the caller of logs (default true)
--disable-stacktrace disable the stacktrace of error logs (default true)
--disable-timestamp disable timestamp output (default true)
-v, --verbosity int number for the log level verbosity (default 1)
```

### SEE ALSO

* [components-cli oci](components-cli_oci.md) -

1 change: 1 addition & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ require (
github.com/mandelsoft/vfs v0.0.0-20201002134249-3c471f64a4d1
github.com/onsi/ginkgo v1.14.0
github.com/onsi/gomega v1.10.1
github.com/opencontainers/distribution-spec v1.0.0-rc1
github.com/opencontainers/go-digest v1.0.0
github.com/opencontainers/image-spec v1.0.1
github.com/prometheus/client_golang v0.9.3
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,8 @@ github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1Cpa
github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY=
github.com/onsi/gomega v1.10.1 h1:o0+MgICZLuZ7xjH7Vx6zS/zcu93/BEp1VwkIW1mEXCE=
github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo=
github.com/opencontainers/distribution-spec v1.0.0-rc1 h1:nuQ2aIFPy01fNMoeoY7TCedORpU9Wmm/nkMiGErgrmY=
github.com/opencontainers/distribution-spec v1.0.0-rc1/go.mod h1:copR2flp+jTEvQIFMb6MIx45OkrxzqyjszPDT3hx/5Q=
github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U=
github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM=
github.com/opencontainers/image-spec v1.0.1 h1:JMemWkRwHx4Zj+fVxWoMCFm/8sYGGrUVojFA6h/TRcI=
Expand Down
Loading

0 comments on commit b8f7be9

Please sign in to comment.