Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add spanner instance IAM policy support #214

Merged
merged 34 commits into from
Dec 10, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
d22e041
Add InSpec support for cloud scheduler job
slevenick Nov 1, 2019
12e04a0
Merge pull request #246 from modular-magician/codegen-pr-2577
slevenick Nov 4, 2019
04c0f74
Add L7 ILB fields to RegionBackendService (#244)
modular-magician Nov 5, 2019
1447ad3
Merge branch 'master' into master
Nov 6, 2019
5f54921
[Ansible] Service Usage Services
rambleraptor Nov 7, 2019
6b0cd67
[Ansible] Service Usage Services (#248)
rambleraptor Nov 7, 2019
23ce238
Inspec cloudbilling support
slevenick Nov 13, 2019
06a2a2a
Minor documentation changes (#242)
modular-magician Nov 13, 2019
a36faf6
Merge pull request #251 from modular-magician/codegen-pr-2677
slevenick Nov 13, 2019
3f0c2f9
Merge remote-tracking branch 'gcp/master'
slevenick Nov 13, 2019
14740dd
Billing info fix
slevenick Nov 20, 2019
c9d6ab2
Merge pull request #255 from modular-magician/codegen-pr-2726
slevenick Nov 21, 2019
c2b3c96
Merge remote-tracking branch 'gcp/master'
slevenick Nov 21, 2019
6ca227c
Add cloudbuild_trigger build timeout and CustomizeDiff
c2thorn Nov 21, 2019
35af2e0
Merge pull request #252 from modular-magician/codegen-pr-2711
slevenick Nov 22, 2019
c2ab2e3
Merge branch 'master' into master
Nov 26, 2019
597ae39
Add a kubernetes style resource async class (#253)
modular-magician Dec 2, 2019
b7d8e9e
Merge branch 'master' into master
Dec 3, 2019
ce592cd
fix broken indent in bigquery dataset docs (#259)
modular-magician Dec 3, 2019
2e100db
Merge branch 'master' into master
Dec 4, 2019
e757bdb
Merge remote-tracking branch 'gcp/master'
slevenick Dec 4, 2019
f967e3b
Add support for spanner instance IAM to inspec
slevenick Dec 4, 2019
4116b49
Merge pull request #260 from modular-magician/codegen-pr-2780
slevenick Dec 4, 2019
b1929ea
Add pubsubConfigs to cloud source repository
c2thorn Dec 5, 2019
357f043
Merge pull request #258 from modular-magician/codegen-pr-2769
c2thorn Dec 5, 2019
e3e78b9
correct documentation about multiple ssl certificates (#261)
modular-magician Dec 5, 2019
8e8b7c0
Add route_rules to UrlMap for Traffic Director (#256)
modular-magician Dec 6, 2019
0969d41
Add spanner service account and IAM
slevenick Dec 6, 2019
9b1463e
Merge pull request #266 from modular-magician/codegen-pr-2799
slevenick Dec 6, 2019
afd143c
Add spanner instance IAM policy test
slevenick Dec 6, 2019
7ff4744
Add path_rules to UrlMap (#265)
modular-magician Dec 9, 2019
4685dcc
update compute disk documentation (#267)
modular-magician Dec 9, 2019
8b46d0a
Add path_rules to RegionUrlMap (#269)
modular-magician Dec 9, 2019
d713827
Add route_rules to RegionUrlMap (#270)
modular-magician Dec 10, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/resources/google_compute_disk.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ Properties that can be accessed from the `google_compute_disk` resource:

* `sha256`: The RFC 4648 base64 encoded SHA-256 hash of the customer-supplied encryption key that protects this resource.

* `kms_key_name`: The name of the encryption key that is stored in Google Cloud KMS.
* `kms_key_name`: The name of the encryption key that is stored in Google Cloud KMS. Your project's Compute Engine System service account (`service-{{PROJECT_NUMBER}}@compute-system.iam.gserviceaccount.com`) must have `roles/cloudkms.cryptoKeyEncrypterDecrypter` to use this feature.

* `source_snapshot`: The source snapshot used to create this disk. You can provide this as a partial or full URL to the resource. If the snapshot is in another project than this disk, you must supply a full URL. For example, the following are valid values: * `https://www.googleapis.com/compute/v1/projects/project/global/snapshots/snapshot` * `projects/project/global/snapshots/snapshot` * `global/snapshots/snapshot`

Expand Down
2 changes: 1 addition & 1 deletion docs/resources/google_compute_target_https_proxy.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Properties that can be accessed from the `google_compute_target_https_proxy` res

* `quic_override`: Specifies the QUIC override policy for this resource. This determines whether the load balancer will attempt to negotiate QUIC with clients or not. Can specify one of NONE, ENABLE, or DISABLE. If NONE is specified, uses the QUIC policy with no user overrides, which is equivalent to DISABLE. Not specifying this field is equivalent to specifying NONE.

* `ssl_certificates`: A list of SslCertificate resources that are used to authenticate connections between users and the load balancer. Currently, exactly one SSL certificate must be specified.
* `ssl_certificates`: A list of SslCertificate resources that are used to authenticate connections between users and the load balancer. At least one SSL certificate must be specified.

* `ssl_policy`: A reference to the SslPolicy resource that will be associated with the TargetHttpsProxy resource. If not set, the TargetHttpsProxy resource will not have any SSL policy configured.

Expand Down
364 changes: 352 additions & 12 deletions docs/resources/google_compute_url_map.md

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion docs/resources/google_compute_url_maps.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@ See [google_compute_url_map.md](google_compute_url_map.md) for more detailed inf
* `creation_timestamps`: an array of `google_compute_url_map` creation_timestamp
* `default_services`: an array of `google_compute_url_map` default_service
* `descriptions`: an array of `google_compute_url_map` description
* `host_rules`: an array of `google_compute_url_map` host_rules
* `ids`: an array of `google_compute_url_map` id
* `fingerprints`: an array of `google_compute_url_map` fingerprint
* `header_actions`: an array of `google_compute_url_map` header_action
* `host_rules`: an array of `google_compute_url_map` host_rules
* `names`: an array of `google_compute_url_map` name
* `path_matchers`: an array of `google_compute_url_map` path_matchers
* `tests`: an array of `google_compute_url_map` tests
Expand Down
1 change: 1 addition & 0 deletions docs/resources/google_sourcerepo_repositories.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ See [google_sourcerepo_repository.md](google_sourcerepo_repository.md) for more
* `names`: an array of `google_sourcerepo_repository` name
* `urls`: an array of `google_sourcerepo_repository` url
* `sizes`: an array of `google_sourcerepo_repository` size
* `pubsub_configs`: an array of `google_sourcerepo_repository` pubsub_configs

## Filter Criteria
This resource supports all of the above properties as filter criteria, which can be used
Expand Down
2 changes: 2 additions & 0 deletions docs/resources/google_sourcerepo_repository.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ Properties that can be accessed from the `google_sourcerepo_repository` resource

* `size`: The disk usage of the repo, in bytes.

* `pubsub_configs`: How this repository publishes a change in the repository through Cloud Pub/Sub. Keyed by the topic names.


## GCP Permissions

Expand Down
46 changes: 46 additions & 0 deletions docs/resources/google_spanner_instance_iam_policy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
---
title: About the google_spanner_instance_iam_policy resource
platform: gcp
---

## Syntax
A `google_spanner_instance_iam_policy` is used to test a Google Instance Iam Policy resource

## Examples
```
describe google_spanner_instance_iam_policy(project: "project", name: "name") do
it { should exist }
end

google_spanner_instance_iam_policy(project: "project", name: "name").bindings.each do |binding|
describe binding do
its('role') { should eq 'roles/editor'}
its('members') { should include 'user:[email protected]'}
end
end
```

## Properties
Properties that can be accessed from the `google_spanner_instance_iam_policy` resource:

* `bindings`: Associates a list of members to a role.

* `role`: Role that is assigned to members. For example, roles/viewer, roles/editor, or roles/owner.

* `members`: Specifies the identities requesting access for a Cloud Platform resource.

* `audit_configs`: Specifies cloud audit logging configuration for this policy.

* `service`: Specifies a service that will be enabled for audit logging. For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices` is a special value that covers all services.

* `audit_log_configs`: The configuration for logging of each type of permission.

* `log_type`: The log type that this config enables. For example, ADMIN_READ, DATA_WRITE or DATA_READ

* `exempted_members`: Specifies the identities that do not cause logging for this type of permission.



## GCP Permissions

Ensure the [Cloud Spanner API](https://console.cloud.google.com/apis/library/spanner.googleapis.com/) is enabled for the current project.
45 changes: 45 additions & 0 deletions libraries/google/compute/property/urlmap_header_action.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# frozen_string_literal: false

# ----------------------------------------------------------------------------
#
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
#
# ----------------------------------------------------------------------------
#
# This file is automatically generated by Magic Modules and manual
# changes will be clobbered when the file is regenerated.
#
# Please read more about how to change this file in README.md and
# CONTRIBUTING.md located at the root of this package.
#
# ----------------------------------------------------------------------------
require 'google/compute/property/urlmap_header_action_request_headers_to_add'
require 'google/compute/property/urlmap_header_action_response_headers_to_add'
module GoogleInSpec
module Compute
module Property
class UrlMapHeaderAction
attr_reader :request_headers_to_add

attr_reader :request_headers_to_remove

attr_reader :response_headers_to_add

attr_reader :response_headers_to_remove

def initialize(args = nil, parent_identifier = nil)
return if args.nil?
@parent_identifier = parent_identifier
@request_headers_to_add = GoogleInSpec::Compute::Property::UrlMapHeaderActionRequestHeadersToAddArray.parse(args['requestHeadersToAdd'], to_s)
@request_headers_to_remove = args['requestHeadersToRemove']
@response_headers_to_add = GoogleInSpec::Compute::Property::UrlMapHeaderActionResponseHeadersToAddArray.parse(args['responseHeadersToAdd'], to_s)
@response_headers_to_remove = args['responseHeadersToRemove']
end

def to_s
"#{@parent_identifier} UrlMapHeaderAction"
end
end
end
end
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# frozen_string_literal: false

# ----------------------------------------------------------------------------
#
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
#
# ----------------------------------------------------------------------------
#
# This file is automatically generated by Magic Modules and manual
# changes will be clobbered when the file is regenerated.
#
# Please read more about how to change this file in README.md and
# CONTRIBUTING.md located at the root of this package.
#
# ----------------------------------------------------------------------------
module GoogleInSpec
module Compute
module Property
class UrlMapHeaderActionRequestHeadersToAdd
attr_reader :header_name

attr_reader :header_value

attr_reader :replace

def initialize(args = nil, parent_identifier = nil)
return if args.nil?
@parent_identifier = parent_identifier
@header_name = args['headerName']
@header_value = args['headerValue']
@replace = args['replace']
end

def to_s
"#{@parent_identifier} UrlMapHeaderActionRequestHeadersToAdd"
end
end

class UrlMapHeaderActionRequestHeadersToAddArray
def self.parse(value, parent_identifier)
return if value.nil?
return UrlMapHeaderActionRequestHeadersToAdd.new(value, parent_identifier) unless value.is_a?(::Array)
value.map { |v| UrlMapHeaderActionRequestHeadersToAdd.new(v, parent_identifier) }
end
end
end
end
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# frozen_string_literal: false

# ----------------------------------------------------------------------------
#
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
#
# ----------------------------------------------------------------------------
#
# This file is automatically generated by Magic Modules and manual
# changes will be clobbered when the file is regenerated.
#
# Please read more about how to change this file in README.md and
# CONTRIBUTING.md located at the root of this package.
#
# ----------------------------------------------------------------------------
module GoogleInSpec
module Compute
module Property
class UrlMapHeaderActionResponseHeadersToAdd
attr_reader :header_name

attr_reader :header_value

attr_reader :replace

def initialize(args = nil, parent_identifier = nil)
return if args.nil?
@parent_identifier = parent_identifier
@header_name = args['headerName']
@header_value = args['headerValue']
@replace = args['replace']
end

def to_s
"#{@parent_identifier} UrlMapHeaderActionResponseHeadersToAdd"
end
end

class UrlMapHeaderActionResponseHeadersToAddArray
def self.parse(value, parent_identifier)
return if value.nil?
return UrlMapHeaderActionResponseHeadersToAdd.new(value, parent_identifier) unless value.is_a?(::Array)
value.map { |v| UrlMapHeaderActionResponseHeadersToAdd.new(v, parent_identifier) }
end
end
end
end
end
10 changes: 10 additions & 0 deletions libraries/google/compute/property/urlmap_path_matchers.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,11 @@
# CONTRIBUTING.md located at the root of this package.
#
# ----------------------------------------------------------------------------
require 'google/compute/property/urlmap_path_matchers_header_action'
require 'google/compute/property/urlmap_path_matchers_header_action_request_headers_to_add'
require 'google/compute/property/urlmap_path_matchers_header_action_response_headers_to_add'
require 'google/compute/property/urlmap_path_matchers_path_rules'
require 'google/compute/property/urlmap_path_matchers_route_rules'
module GoogleInSpec
module Compute
module Property
Expand All @@ -22,17 +26,23 @@ class UrlMapPathMatchers

attr_reader :description

attr_reader :header_action

attr_reader :name

attr_reader :path_rules

attr_reader :route_rules

def initialize(args = nil, parent_identifier = nil)
return if args.nil?
@parent_identifier = parent_identifier
@default_service = args['defaultService']
@description = args['description']
@header_action = GoogleInSpec::Compute::Property::UrlMapPathMatchersHeaderAction.new(args['headerAction'], to_s)
@name = args['name']
@path_rules = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesArray.parse(args['pathRules'], to_s)
@route_rules = GoogleInSpec::Compute::Property::UrlMapPathMatchersRouteRulesArray.parse(args['routeRules'], to_s)
end

def to_s
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# frozen_string_literal: false

# ----------------------------------------------------------------------------
#
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
#
# ----------------------------------------------------------------------------
#
# This file is automatically generated by Magic Modules and manual
# changes will be clobbered when the file is regenerated.
#
# Please read more about how to change this file in README.md and
# CONTRIBUTING.md located at the root of this package.
#
# ----------------------------------------------------------------------------
require 'google/compute/property/urlmap_path_matchers_header_action_request_headers_to_add'
require 'google/compute/property/urlmap_path_matchers_header_action_response_headers_to_add'
module GoogleInSpec
module Compute
module Property
class UrlMapPathMatchersHeaderAction
attr_reader :request_headers_to_add

attr_reader :request_headers_to_remove

attr_reader :response_headers_to_add

attr_reader :response_headers_to_remove

def initialize(args = nil, parent_identifier = nil)
return if args.nil?
@parent_identifier = parent_identifier
@request_headers_to_add = GoogleInSpec::Compute::Property::UrlMapPathMatchersHeaderActionRequestHeadersToAddArray.parse(args['requestHeadersToAdd'], to_s)
@request_headers_to_remove = args['requestHeadersToRemove']
@response_headers_to_add = GoogleInSpec::Compute::Property::UrlMapPathMatchersHeaderActionResponseHeadersToAddArray.parse(args['responseHeadersToAdd'], to_s)
@response_headers_to_remove = args['responseHeadersToRemove']
end

def to_s
"#{@parent_identifier} UrlMapPathMatchersHeaderAction"
end
end
end
end
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# frozen_string_literal: false

# ----------------------------------------------------------------------------
#
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
#
# ----------------------------------------------------------------------------
#
# This file is automatically generated by Magic Modules and manual
# changes will be clobbered when the file is regenerated.
#
# Please read more about how to change this file in README.md and
# CONTRIBUTING.md located at the root of this package.
#
# ----------------------------------------------------------------------------
module GoogleInSpec
module Compute
module Property
class UrlMapPathMatchersHeaderActionRequestHeadersToAdd
attr_reader :header_name

attr_reader :header_value

attr_reader :replace

def initialize(args = nil, parent_identifier = nil)
return if args.nil?
@parent_identifier = parent_identifier
@header_name = args['headerName']
@header_value = args['headerValue']
@replace = args['replace']
end

def to_s
"#{@parent_identifier} UrlMapPathMatchersHeaderActionRequestHeadersToAdd"
end
end

class UrlMapPathMatchersHeaderActionRequestHeadersToAddArray
def self.parse(value, parent_identifier)
return if value.nil?
return UrlMapPathMatchersHeaderActionRequestHeadersToAdd.new(value, parent_identifier) unless value.is_a?(::Array)
value.map { |v| UrlMapPathMatchersHeaderActionRequestHeadersToAdd.new(v, parent_identifier) }
end
end
end
end
end
Loading