Skip to content
This repository was archived by the owner on Nov 14, 2024. It is now read-only.

Commit 92cd704

Browse files
slevenickskpaterson
authored andcommitted
InSpec Add back pathmatchers except for routerules
Signed-off-by: Modular Magician <magic-modules@google.com>
1 parent 390dda3 commit 92cd704

File tree

25 files changed

+1110
-0
lines changed

25 files changed

+1110
-0
lines changed

docs/resources/google_compute_url_map.md

+144
Large diffs are not rendered by default.

docs/resources/google_compute_url_maps.md

+1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ See [google_compute_url_map.md](google_compute_url_map.md) for more detailed inf
2525
* `header_actions`: an array of `google_compute_url_map` header_action
2626
* `host_rules`: an array of `google_compute_url_map` host_rules
2727
* `names`: an array of `google_compute_url_map` name
28+
* `path_matchers`: an array of `google_compute_url_map` path_matchers
2829
* `tests`: an array of `google_compute_url_map` tests
2930

3031
## Filter Criteria
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
# frozen_string_literal: false
2+
3+
# ----------------------------------------------------------------------------
4+
#
5+
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
6+
#
7+
# ----------------------------------------------------------------------------
8+
#
9+
# This file is automatically generated by Magic Modules and manual
10+
# changes will be clobbered when the file is regenerated.
11+
#
12+
# Please read more about how to change this file in README.md and
13+
# CONTRIBUTING.md located at the root of this package.
14+
#
15+
# ----------------------------------------------------------------------------
16+
require 'google/compute/property/urlmap_path_matchers_header_action'
17+
require 'google/compute/property/urlmap_path_matchers_header_action_request_headers_to_add'
18+
require 'google/compute/property/urlmap_path_matchers_header_action_response_headers_to_add'
19+
require 'google/compute/property/urlmap_path_matchers_path_rules'
20+
module GoogleInSpec
21+
module Compute
22+
module Property
23+
class UrlMapPathMatchers
24+
attr_reader :default_service
25+
26+
attr_reader :description
27+
28+
attr_reader :header_action
29+
30+
attr_reader :name
31+
32+
attr_reader :path_rules
33+
34+
def initialize(args = nil, parent_identifier = nil)
35+
return if args.nil?
36+
@parent_identifier = parent_identifier
37+
@default_service = args['defaultService']
38+
@description = args['description']
39+
@header_action = GoogleInSpec::Compute::Property::UrlMapPathMatchersHeaderAction.new(args['headerAction'], to_s)
40+
@name = args['name']
41+
@path_rules = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesArray.parse(args['pathRules'], to_s)
42+
end
43+
44+
def to_s
45+
"#{@parent_identifier} UrlMapPathMatchers"
46+
end
47+
end
48+
49+
class UrlMapPathMatchersArray
50+
def self.parse(value, parent_identifier)
51+
return if value.nil?
52+
return UrlMapPathMatchers.new(value, parent_identifier) unless value.is_a?(::Array)
53+
value.map { |v| UrlMapPathMatchers.new(v, parent_identifier) }
54+
end
55+
end
56+
end
57+
end
58+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# frozen_string_literal: false
2+
3+
# ----------------------------------------------------------------------------
4+
#
5+
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
6+
#
7+
# ----------------------------------------------------------------------------
8+
#
9+
# This file is automatically generated by Magic Modules and manual
10+
# changes will be clobbered when the file is regenerated.
11+
#
12+
# Please read more about how to change this file in README.md and
13+
# CONTRIBUTING.md located at the root of this package.
14+
#
15+
# ----------------------------------------------------------------------------
16+
require 'google/compute/property/urlmap_path_matchers_header_action_request_headers_to_add'
17+
require 'google/compute/property/urlmap_path_matchers_header_action_response_headers_to_add'
18+
module GoogleInSpec
19+
module Compute
20+
module Property
21+
class UrlMapPathMatchersHeaderAction
22+
attr_reader :request_headers_to_add
23+
24+
attr_reader :request_headers_to_remove
25+
26+
attr_reader :response_headers_to_add
27+
28+
attr_reader :response_headers_to_remove
29+
30+
def initialize(args = nil, parent_identifier = nil)
31+
return if args.nil?
32+
@parent_identifier = parent_identifier
33+
@request_headers_to_add = GoogleInSpec::Compute::Property::UrlMapPathMatchersHeaderActionRequestHeadersToAddArray.parse(args['requestHeadersToAdd'], to_s)
34+
@request_headers_to_remove = args['requestHeadersToRemove']
35+
@response_headers_to_add = GoogleInSpec::Compute::Property::UrlMapPathMatchersHeaderActionResponseHeadersToAddArray.parse(args['responseHeadersToAdd'], to_s)
36+
@response_headers_to_remove = args['responseHeadersToRemove']
37+
end
38+
39+
def to_s
40+
"#{@parent_identifier} UrlMapPathMatchersHeaderAction"
41+
end
42+
end
43+
end
44+
end
45+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# frozen_string_literal: false
2+
3+
# ----------------------------------------------------------------------------
4+
#
5+
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
6+
#
7+
# ----------------------------------------------------------------------------
8+
#
9+
# This file is automatically generated by Magic Modules and manual
10+
# changes will be clobbered when the file is regenerated.
11+
#
12+
# Please read more about how to change this file in README.md and
13+
# CONTRIBUTING.md located at the root of this package.
14+
#
15+
# ----------------------------------------------------------------------------
16+
module GoogleInSpec
17+
module Compute
18+
module Property
19+
class UrlMapPathMatchersHeaderActionRequestHeadersToAdd
20+
attr_reader :header_name
21+
22+
attr_reader :header_value
23+
24+
attr_reader :replace
25+
26+
def initialize(args = nil, parent_identifier = nil)
27+
return if args.nil?
28+
@parent_identifier = parent_identifier
29+
@header_name = args['headerName']
30+
@header_value = args['headerValue']
31+
@replace = args['replace']
32+
end
33+
34+
def to_s
35+
"#{@parent_identifier} UrlMapPathMatchersHeaderActionRequestHeadersToAdd"
36+
end
37+
end
38+
39+
class UrlMapPathMatchersHeaderActionRequestHeadersToAddArray
40+
def self.parse(value, parent_identifier)
41+
return if value.nil?
42+
return UrlMapPathMatchersHeaderActionRequestHeadersToAdd.new(value, parent_identifier) unless value.is_a?(::Array)
43+
value.map { |v| UrlMapPathMatchersHeaderActionRequestHeadersToAdd.new(v, parent_identifier) }
44+
end
45+
end
46+
end
47+
end
48+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# frozen_string_literal: false
2+
3+
# ----------------------------------------------------------------------------
4+
#
5+
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
6+
#
7+
# ----------------------------------------------------------------------------
8+
#
9+
# This file is automatically generated by Magic Modules and manual
10+
# changes will be clobbered when the file is regenerated.
11+
#
12+
# Please read more about how to change this file in README.md and
13+
# CONTRIBUTING.md located at the root of this package.
14+
#
15+
# ----------------------------------------------------------------------------
16+
module GoogleInSpec
17+
module Compute
18+
module Property
19+
class UrlMapPathMatchersHeaderActionResponseHeadersToAdd
20+
attr_reader :header_name
21+
22+
attr_reader :header_value
23+
24+
attr_reader :replace
25+
26+
def initialize(args = nil, parent_identifier = nil)
27+
return if args.nil?
28+
@parent_identifier = parent_identifier
29+
@header_name = args['headerName']
30+
@header_value = args['headerValue']
31+
@replace = args['replace']
32+
end
33+
34+
def to_s
35+
"#{@parent_identifier} UrlMapPathMatchersHeaderActionResponseHeadersToAdd"
36+
end
37+
end
38+
39+
class UrlMapPathMatchersHeaderActionResponseHeadersToAddArray
40+
def self.parse(value, parent_identifier)
41+
return if value.nil?
42+
return UrlMapPathMatchersHeaderActionResponseHeadersToAdd.new(value, parent_identifier) unless value.is_a?(::Array)
43+
value.map { |v| UrlMapPathMatchersHeaderActionResponseHeadersToAdd.new(v, parent_identifier) }
44+
end
45+
end
46+
end
47+
end
48+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
# frozen_string_literal: false
2+
3+
# ----------------------------------------------------------------------------
4+
#
5+
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
6+
#
7+
# ----------------------------------------------------------------------------
8+
#
9+
# This file is automatically generated by Magic Modules and manual
10+
# changes will be clobbered when the file is regenerated.
11+
#
12+
# Please read more about how to change this file in README.md and
13+
# CONTRIBUTING.md located at the root of this package.
14+
#
15+
# ----------------------------------------------------------------------------
16+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action'
17+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_cors_policy'
18+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_fault_injection_policy'
19+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_fault_injection_policy_abort'
20+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_fault_injection_policy_delay'
21+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_fault_injection_policy_delay_fixed_delay'
22+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_request_mirror_policy'
23+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_retry_policy'
24+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_retry_policy_per_try_timeout'
25+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_timeout'
26+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_url_rewrite'
27+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_weighted_backend_services'
28+
require 'google/compute/property/urlmap_path_matchers_path_rules_url_redirect'
29+
module GoogleInSpec
30+
module Compute
31+
module Property
32+
class UrlMapPathMatchersPathRules
33+
attr_reader :service
34+
35+
attr_reader :paths
36+
37+
attr_reader :route_action
38+
39+
attr_reader :url_redirect
40+
41+
def initialize(args = nil, parent_identifier = nil)
42+
return if args.nil?
43+
@parent_identifier = parent_identifier
44+
@service = args['service']
45+
@paths = args['paths']
46+
@route_action = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesRouteAction.new(args['routeAction'], to_s)
47+
@url_redirect = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesUrlRedirect.new(args['urlRedirect'], to_s)
48+
end
49+
50+
def to_s
51+
"#{@parent_identifier} UrlMapPathMatchersPathRules"
52+
end
53+
end
54+
55+
class UrlMapPathMatchersPathRulesArray
56+
def self.parse(value, parent_identifier)
57+
return if value.nil?
58+
return UrlMapPathMatchersPathRules.new(value, parent_identifier) unless value.is_a?(::Array)
59+
value.map { |v| UrlMapPathMatchersPathRules.new(v, parent_identifier) }
60+
end
61+
end
62+
end
63+
end
64+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# frozen_string_literal: false
2+
3+
# ----------------------------------------------------------------------------
4+
#
5+
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
6+
#
7+
# ----------------------------------------------------------------------------
8+
#
9+
# This file is automatically generated by Magic Modules and manual
10+
# changes will be clobbered when the file is regenerated.
11+
#
12+
# Please read more about how to change this file in README.md and
13+
# CONTRIBUTING.md located at the root of this package.
14+
#
15+
# ----------------------------------------------------------------------------
16+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_cors_policy'
17+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_fault_injection_policy'
18+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_fault_injection_policy_abort'
19+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_fault_injection_policy_delay'
20+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_fault_injection_policy_delay_fixed_delay'
21+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_request_mirror_policy'
22+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_retry_policy'
23+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_retry_policy_per_try_timeout'
24+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_timeout'
25+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_url_rewrite'
26+
require 'google/compute/property/urlmap_path_matchers_path_rules_route_action_weighted_backend_services'
27+
module GoogleInSpec
28+
module Compute
29+
module Property
30+
class UrlMapPathMatchersPathRulesRouteAction
31+
attr_reader :cors_policy
32+
33+
attr_reader :fault_injection_policy
34+
35+
attr_reader :request_mirror_policy
36+
37+
attr_reader :retry_policy
38+
39+
attr_reader :timeout
40+
41+
attr_reader :url_rewrite
42+
43+
attr_reader :weighted_backend_services
44+
45+
def initialize(args = nil, parent_identifier = nil)
46+
return if args.nil?
47+
@parent_identifier = parent_identifier
48+
@cors_policy = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesRouteActionCorsPolicy.new(args['corsPolicy'], to_s)
49+
@fault_injection_policy = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesRouteActionFaultInjectionPolicy.new(args['faultInjectionPolicy'], to_s)
50+
@request_mirror_policy = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesRouteActionRequestMirrorPolicy.new(args['requestMirrorPolicy'], to_s)
51+
@retry_policy = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesRouteActionRetryPolicy.new(args['retryPolicy'], to_s)
52+
@timeout = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesRouteActionTimeout.new(args['timeout'], to_s)
53+
@url_rewrite = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesRouteActionUrlRewrite.new(args['urlRewrite'], to_s)
54+
@weighted_backend_services = GoogleInSpec::Compute::Property::UrlMapPathMatchersPathRulesRouteActionWeightedBackendServicesArray.parse(args['weightedBackendServices'], to_s)
55+
end
56+
57+
def to_s
58+
"#{@parent_identifier} UrlMapPathMatchersPathRulesRouteAction"
59+
end
60+
end
61+
end
62+
end
63+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# frozen_string_literal: false
2+
3+
# ----------------------------------------------------------------------------
4+
#
5+
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
6+
#
7+
# ----------------------------------------------------------------------------
8+
#
9+
# This file is automatically generated by Magic Modules and manual
10+
# changes will be clobbered when the file is regenerated.
11+
#
12+
# Please read more about how to change this file in README.md and
13+
# CONTRIBUTING.md located at the root of this package.
14+
#
15+
# ----------------------------------------------------------------------------
16+
module GoogleInSpec
17+
module Compute
18+
module Property
19+
class UrlMapPathMatchersPathRulesRouteActionCorsPolicy
20+
attr_reader :allow_credentials
21+
22+
attr_reader :allow_headers
23+
24+
attr_reader :allow_methods
25+
26+
attr_reader :allow_origin_regexes
27+
28+
attr_reader :allow_origins
29+
30+
attr_reader :disabled
31+
32+
attr_reader :expose_headers
33+
34+
attr_reader :max_age
35+
36+
def initialize(args = nil, parent_identifier = nil)
37+
return if args.nil?
38+
@parent_identifier = parent_identifier
39+
@allow_credentials = args['allowCredentials']
40+
@allow_headers = args['allowHeaders']
41+
@allow_methods = args['allowMethods']
42+
@allow_origin_regexes = args['allowOriginRegexes']
43+
@allow_origins = args['allowOrigins']
44+
@disabled = args['disabled']
45+
@expose_headers = args['exposeHeaders']
46+
@max_age = args['maxAge']
47+
end
48+
49+
def to_s
50+
"#{@parent_identifier} UrlMapPathMatchersPathRulesRouteActionCorsPolicy"
51+
end
52+
end
53+
end
54+
end
55+
end

0 commit comments

Comments
 (0)