github.com/oam-dev/kubevela@v1.9.11/vela-templates/definitions/internal/workflowstep/share-cloud-resource.cue (about)

     1  import (
     2  	"vela/op"
     3  )
     4  
     5  "share-cloud-resource": {
     6  	type: "workflow-step"
     7  	annotations: {
     8  		"category": "Application Delivery"
     9  	}
    10  	labels: {
    11  		"scope": "Application"
    12  	}
    13  	description: "Sync secrets created by terraform component to runtime clusters so that runtime clusters can share the created cloud resource."
    14  }
    15  template: {
    16  	app: op.#ShareCloudResource & {
    17  		env:        parameter.env
    18  		policy:     parameter.policy
    19  		placements: parameter.placements
    20  		// context.namespace indicates the namespace of the app
    21  		namespace: context.namespace
    22  		// context.namespace indicates the name of the app
    23  		name: context.name
    24  	}
    25  
    26  	parameter: {
    27  		// +usage=Declare the location to bind
    28  		placements: [...{
    29  			namespace?: string
    30  			cluster?:   string
    31  		}]
    32  		// +usage=Declare the name of the env-binding policy, if empty, the first env-binding policy will be used
    33  		policy: *"" | string
    34  		// +usage=Declare the name of the env in policy
    35  		env: string
    36  	}
    37  }