Skip to content

How to link resources in crossplane for openstack provider. #92

Answered by schlakob
ale9412 asked this question in Q&A
Discussion options

You must be logged in to vote

Hi,
it is theoretical possible to implement the cross-resource references you mentioned. We mostly use functions for our compositions and accomplish specially your use case with the go-templating function . There you can just use any value from and for other Resources, so this is really flexible.

For example we use it like this, to reference a Project id in a RoleAssignment:

---
apiVersion: identity.openstack.crossplane.io/v1alpha1
kind: ProjectV3
metadata:
  name: test-project
  annotations:
    crossplane.io/composition-resource-name: project
spec:
  forProvider:
    name: test-stuff
    domainId: {{ $envContext.projects.domainId | quote }}
  providerConfigRef:
    name: {{ .observed.co…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@ale9412
Comment options

Answer selected by ale9412
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants