Skip to content

Commit

Permalink
docs: add resolver chapter
Browse files Browse the repository at this point in the history
Signed-off-by: Nico Braun <[email protected]>
  • Loading branch information
bluebrown committed Jul 25, 2023
1 parent 2dabbca commit e9572e4
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 5 deletions.
1 change: 1 addition & 0 deletions docs/src/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
- [Pull Requests](./configuration/pull-requests.md)
- [Scopes](./configuration/scopes.md)
- [File Associations](./configuration/file-associations.md)
- [Resolvers](./configuration/resolvers.md)
- [Registry Auth](./configuration/registry-auth.md)
- [Deployment](./deployment/index.md)
- [Kubernetes](./deployment/kubernetes.md)
Expand Down
6 changes: 1 addition & 5 deletions docs/src/configuration/file-associations.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
# File Associations

In order to find image references, the file must be of a known type. Currently
known types are `kubernetes`, `docker-compose` and `ko-build`.

The type of a given yaml file is determined by using glob to math the filename.
The default matching rules look like this:

Expand All @@ -28,5 +25,4 @@ subscriptions:
pattern: "*"
```
> **Note** If there is a filetype you would to use, that is currently not
supported, please open and issue so we can can add it to the codebase.
If the builtin resolvers are not sufficient. You can [create your own resolver](./resolvers.md).
17 changes: 17 additions & 0 deletions docs/src/configuration/resolvers.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Resolvers

It is possible to create custom resolvers, to look up image references in yaml
files.

```yaml
resolvers:
- name: my-custom
paths:
- path.to.image
- another.path
```
If a resolvers is used, via a [file association](./file-associations.md), image
references at all paths of the resolver are handled. Kobold does not stop on
first match. Additionally, if a path does not exist, kobold will continue with
the next path, without error or warning.

0 comments on commit e9572e4

Please sign in to comment.