crossplane / docs

Repo for Crossplane documentation.
https://docs.crossplane.io
Other
49 stars 110 forks source link

Document composition function credentials #762

Open negz opened 5 months ago

negz commented 5 months ago

https://github.com/crossplane/crossplane/pull/5543 adds the ability to pass credentials to a composition function.

apiVersion: apiextensions.crossplane.io/v1
kind: Composition
metadata:
  name: parent
spec:
  compositeTypeRef:
    apiVersion: nop.example.org/v1alpha1
    kind: XNopResource
  mode: Pipeline
  pipeline:
  - step: example
    functionRef:
      name: function-needs-a-secret
    credentials:
    - name: credentials-for-something
      source: Secret
      secretRef:
        namespace: crossplane-system
        name: super-secret
jbw976 commented 3 months ago

Here's a demo repo that shows how to use credentials with functions - could be useful for writing the documentation.

https://github.com/jbw976/demo-xfn-creds/