Skip to content

Commit

Permalink
Add product to kind
Browse files Browse the repository at this point in the history
  • Loading branch information
rileykarson committed Aug 27, 2019
1 parent 59b2d96 commit ca80b46
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 37 deletions.
64 changes: 32 additions & 32 deletions build/kcc/servicemappings/compute.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ spec:
resourceReferences:
- key: subnetworkRef
tfField: subnetwork
kind: Subnetwork
kind: ComputeSubnetwork
required: false
- name: google_compute_autoscaler
kind: ComputeAutoscaler
Expand All @@ -25,7 +25,7 @@ spec:
resourceReferences:
- key: targetRef
tfField: target
kind: InstanceGroupManager
kind: ComputeInstanceGroupManager
required: true
- name: google_compute_backend_bucket
kind: ComputeBackendBucket
Expand Down Expand Up @@ -62,7 +62,7 @@ spec:
resourceReferences:
- key: typeRef
tfField: type
kind: DiskType
kind: ComputeDiskType
required: false
- name: google_compute_firewall
kind: ComputeFirewall
Expand All @@ -72,7 +72,7 @@ spec:
resourceReferences:
- key: networkRef
tfField: network
kind: Network
kind: ComputeNetwork
required: true
- name: google_compute_forwarding_rule
kind: ComputeForwardingRule
Expand All @@ -82,19 +82,19 @@ spec:
resourceReferences:
- key: backendServiceRef
tfField: backendService
kind: BackendService
kind: ComputeBackendService
required: false
- key: networkRef
tfField: network
kind: Network
kind: ComputeNetwork
required: false
- key: subnetworkRef
tfField: subnetwork
kind: Subnetwork
kind: ComputeSubnetwork
required: false
- key: targetRef
tfField: target
kind: TargetPool
kind: ComputeTargetPool
required: false
- name: google_compute_global_address
kind: ComputeGlobalAddress
Expand All @@ -104,7 +104,7 @@ spec:
resourceReferences:
- key: networkRef
tfField: network
kind: Network
kind: ComputeNetwork
required: false
- name: google_compute_global_forwarding_rule
kind: ComputeGlobalForwardingRule
Expand Down Expand Up @@ -135,7 +135,7 @@ spec:
resourceReferences:
- key: sourceDiskRef
tfField: sourceDisk
kind: Disk
kind: ComputeDisk
required: false
- name: google_compute_interconnect_attachment
kind: ComputeInterconnectAttachment
Expand All @@ -145,7 +145,7 @@ spec:
resourceReferences:
- key: routerRef
tfField: router
kind: Router
kind: ComputeRouter
required: true
- name: google_compute_network
kind: ComputeNetwork
Expand All @@ -160,7 +160,7 @@ spec:
resourceReferences:
- key: instanceRef
tfField: instance
kind: Instance
kind: ComputeInstance
required: true
- name: google_compute_network_endpoint_group
kind: ComputeNetworkEndpointGroup
Expand All @@ -170,11 +170,11 @@ spec:
resourceReferences:
- key: networkRef
tfField: network
kind: Network
kind: ComputeNetwork
required: true
- key: subnetworkRef
tfField: subnetwork
kind: Subnetwork
kind: ComputeSubnetwork
required: false
- name: google_compute_node_group
kind: ComputeNodeGroup
Expand All @@ -184,7 +184,7 @@ spec:
resourceReferences:
- key: nodeTemplateRef
tfField: nodeTemplate
kind: NodeTemplate
kind: ComputeNodeTemplate
required: true
- name: google_compute_node_template
kind: ComputeNodeTemplate
Expand All @@ -205,7 +205,7 @@ spec:
resourceReferences:
- key: typeRef
tfField: type
kind: RegionDiskType
kind: ComputeRegionDiskType
required: false
- name: google_compute_route
kind: ComputeRoute
Expand All @@ -215,15 +215,15 @@ spec:
resourceReferences:
- key: networkRef
tfField: network
kind: Network
kind: ComputeNetwork
required: true
- key: nextHopInstanceRef
tfField: nextHopInstance
kind: Instance
kind: ComputeInstance
required: false
- key: nextHopVpnTunnelRef
tfField: nextHopVpnTunnel
kind: VpnTunnel
kind: ComputeVpnTunnel
required: false
- name: google_compute_router
kind: ComputeRouter
Expand All @@ -233,7 +233,7 @@ spec:
resourceReferences:
- key: networkRef
tfField: network
kind: Network
kind: ComputeNetwork
required: true
- name: google_compute_snapshot
kind: ComputeSnapshot
Expand All @@ -259,7 +259,7 @@ spec:
resourceReferences:
- key: networkRef
tfField: network
kind: Network
kind: ComputeNetwork
required: true
- name: google_compute_target_http_proxy
kind: ComputeTargetHttpProxy
Expand All @@ -269,7 +269,7 @@ spec:
resourceReferences:
- key: urlMapRef
tfField: urlMap
kind: UrlMap
kind: ComputeUrlMap
required: true
- name: google_compute_target_https_proxy
kind: ComputeTargetHttpsProxy
Expand All @@ -279,11 +279,11 @@ spec:
resourceReferences:
- key: sslPolicyRef
tfField: sslPolicy
kind: SslPolicy
kind: ComputeSslPolicy
required: false
- key: urlMapRef
tfField: urlMap
kind: UrlMap
kind: ComputeUrlMap
required: true
- name: google_compute_target_instance
kind: ComputeTargetInstance
Expand All @@ -293,7 +293,7 @@ spec:
resourceReferences:
- key: instanceRef
tfField: instance
kind: Instance
kind: ComputeInstance
required: true
- name: google_compute_target_ssl_proxy
kind: ComputeTargetSslProxy
Expand All @@ -303,11 +303,11 @@ spec:
resourceReferences:
- key: backendServiceRef
tfField: backendService
kind: BackendService
kind: ComputeBackendService
required: true
- key: sslPolicyRef
tfField: sslPolicy
kind: SslPolicy
kind: ComputeSslPolicy
required: false
- name: google_compute_target_tcp_proxy
kind: ComputeTargetTcpProxy
Expand All @@ -317,7 +317,7 @@ spec:
resourceReferences:
- key: backendServiceRef
tfField: backendService
kind: BackendService
kind: ComputeBackendService
required: true
- name: google_compute_vpn_gateway
kind: ComputeVpnGateway
Expand All @@ -327,7 +327,7 @@ spec:
resourceReferences:
- key: networkRef
tfField: network
kind: Network
kind: ComputeNetwork
required: true
- name: google_compute_url_map
kind: ComputeUrlMap
Expand All @@ -337,7 +337,7 @@ spec:
resourceReferences:
- key: defaultServiceRef
tfField: defaultService
kind: BackendService
kind: ComputeBackendService
required: true
- name: google_compute_vpn_tunnel
kind: ComputeVpnTunnel
Expand All @@ -347,9 +347,9 @@ spec:
resourceReferences:
- key: targetVpnGatewayRef
tfField: targetVpnGateway
kind: VpnGateway
kind: ComputeVpnGateway
required: false
- key: routerRef
tfField: router
kind: Router
kind: ComputeRouter
required: false
2 changes: 1 addition & 1 deletion build/kcc/servicemappings/pubsub.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,5 @@ spec:
resourceReferences:
- key: topicRef
tfField: topic
kind: Topic
kind: PubsubTopic
required: true
2 changes: 1 addition & 1 deletion build/kcc/servicemappings/spanner.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ spec:
resourceReferences:
- key: configRef
tfField: config
kind: InstanceConfig
kind: SpannerInstanceConfig
required: true
- name: google_spanner_database
kind: SpannerDatabase
Expand Down
4 changes: 2 additions & 2 deletions build/kcc/servicemappings/storage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ spec:
resourceReferences:
- key: bucketRef
tfField: bucket
kind: Bucket
kind: StorageBucket
required: true
- name: google_storage_default_object_access_control
kind: StorageDefaultObjectAccessControl
Expand All @@ -25,5 +25,5 @@ spec:
resourceReferences:
- key: bucketRef
tfField: bucket
kind: Bucket
kind: StorageBucket
required: true
2 changes: 1 addition & 1 deletion templates/kcc/product/service_mapping.yaml.erb
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ spec:
<%- references.reject { |p| p.name == 'region' }.each do |property| -%>
- key: <%= property.name.camelize(:lower) %>Ref
tfField: <%= property.name %>
kind: <%= property.resource %>
kind: <%= "#{product.name}#{property.resource}" %>
<%- if property.required -%>
required: true
<% else -%>
Expand Down

0 comments on commit ca80b46

Please sign in to comment.