An open API service indexing awesome lists of open source software.

https://github.com/upbound/olm-bundle

A utility to build an OLM bundle from a stream of YAMLs
https://github.com/upbound/olm-bundle

Last synced: about 1 year ago
JSON representation

A utility to build an OLM bundle from a stream of YAMLs

Awesome Lists containing this project

README

          

# OLM Bundle

This tool can be used to produce an [Operator Lifecycle Manager](https://docs.openshift.com/container-platform/4.7/operators/understanding/olm-packaging-format.html)
bundle from a stream of YAMLs. You can additionally add metadata by using a Helm
`Chart.yaml` file.

Example:
```
helm template | \
olm-bundle \
--chart-file-path /Chart.yaml \
--extra-resources-dir \
--output-dir
```

You can use base template for the generated `ClusterServiceVersion` by having
`clusterserviceversion.yaml.tmpl` in the given output directory. Following is an
example:
```yaml
apiVersion: v1alpha1
kind: ClusterServiceVersion
metadata:
creationTimestamp: null
spec:
minKubeVersion: 1.16.0
maturity: stable
installModes:
- supported: false
type: OwnNamespace
- supported: false
type: SingleNamespace
- supported: false
type: MultiNamespace
- supported: true
type: AllNamespaces
```

Similarly, you can have `annotations.yaml.tmpl` in the output directory to have
it used as base. Following is an example:
```yaml
annotations:
operators.operatorframework.io.bundle.mediatype.v1: "registry+v1"
operators.operatorframework.io.bundle.manifests.v1: "manifests/"
operators.operatorframework.io.bundle.metadata.v1: "metadata/"
operators.operatorframework.io.bundle.package.v1: "test-operator"
operators.operatorframework.io.bundle.channels.v1: "beta,stable"
operators.operatorframework.io.bundle.channel.default.v1: "stable"
```

## Releasing

To release a new version of the tool, run the following command:
```bash
make build.all
```

This will place the binaries in `_output/bin` directory.

Create a new release with a tag and upload all the binaries as assets.