upbound / up

The @upbound CLI
Apache License 2.0
52 stars 41 forks source link

Package composition function types #340

Closed nullable-eth closed 1 year ago

nullable-eth commented 1 year ago

Description of your changes

Add types for identifying new crossplane meta type function.

Fixes #

I have:

How has this code been tested

Using a function template similar to this, added a build.sh file

# up cli currently only supports loading base images from daemon not from local file path
# docker buildx create --driver docker-container --driver-opt image=moby/buildkit:master,network=host --name xfn_build
# docker buildx inspect --bootstrap
# docker buildx use xfn_build
# docker buildx build -o type=oci,dest=./xfn-base.tar  .

docker buildx build --load -t upbound/xfn-template-base:v0.0.1 .

# possibly check up version and exit if not new enough to recognize Function meta type
up xpkg build --controller upbound/xfn-template-base:v0.0.1

After running build.sh the xpkg was built and annotated correctly by up.