-
Notifications
You must be signed in to change notification settings - Fork 71
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Automatically generated by magic modules for service: orgpolicy and r…
…esource: Projects__policy. This commit includes the following changes: - Singular Resource - Plural Resource - Documentation updates - Terraform configuration - Integration tests Signed-off-by: Samir Anand <sam.sunny001@gmail.com>
- Loading branch information
1 parent
a17da32
commit c98db95
Showing
19 changed files
with
973 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
--- | ||
title: About the google_orgpolicy_project_policies resource | ||
platform: gcp | ||
--- | ||
|
||
## Syntax | ||
A `google_orgpolicy_project_policies` is used to test a Google ProjectPolicy resource | ||
|
||
## Examples | ||
``` | ||
describe google_orgpolicy_project_policies(parent: ' value_parent') do | ||
it { should exist } | ||
end | ||
``` | ||
|
||
## Properties | ||
Properties that can be accessed from the `google_orgpolicy_project_policies` resource: | ||
|
||
See [google_orgpolicy_project_policy.md](google_orgpolicy_project_policy.md) for more detailed information | ||
* `dry_run_specs`: an array of `google_orgpolicy_project_policy` dry_run_spec | ||
* `specs`: an array of `google_orgpolicy_project_policy` spec | ||
* `names`: an array of `google_orgpolicy_project_policy` name | ||
* `alternates`: an array of `google_orgpolicy_project_policy` alternate | ||
|
||
## Filter Criteria | ||
This resource supports all of the above properties as filter criteria, which can be used | ||
with `where` as a block or a method. | ||
|
||
## GCP Permissions | ||
|
||
Ensure the [None](https://console.cloud.google.com/apis/library/orgpolicy.googleapis.com/) is enabled for the current project. |
Large diffs are not rendered by default.
Oops, something went wrong.
39 changes: 39 additions & 0 deletions
39
libraries/google/orgpolicy/property/projectpolicy_alternate.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# frozen_string_literal: false | ||
|
||
# ---------------------------------------------------------------------------- | ||
# | ||
# *** AUTO GENERATED CODE *** Type: MMv1 *** | ||
# | ||
# ---------------------------------------------------------------------------- | ||
# | ||
# 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/orgpolicy/property/projectpolicy_alternate_spec' | ||
require 'google/orgpolicy/property/projectpolicy_alternate_spec_rules' | ||
module GoogleInSpec | ||
module Orgpolicy | ||
module Property | ||
class ProjectPolicyAlternate | ||
attr_reader :launch | ||
|
||
attr_reader :spec | ||
|
||
def initialize(args = nil, parent_identifier = nil) | ||
return if args.nil? | ||
@parent_identifier = parent_identifier | ||
@launch = args['launch'] | ||
@spec = GoogleInSpec::Orgpolicy::Property::ProjectPolicyAlternateSpec.new(args['spec'], to_s) | ||
end | ||
|
||
def to_s | ||
"#{@parent_identifier} ProjectPolicyAlternate" | ||
end | ||
end | ||
end | ||
end | ||
end |
47 changes: 47 additions & 0 deletions
47
libraries/google/orgpolicy/property/projectpolicy_alternate_spec.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# frozen_string_literal: false | ||
|
||
# ---------------------------------------------------------------------------- | ||
# | ||
# *** AUTO GENERATED CODE *** Type: MMv1 *** | ||
# | ||
# ---------------------------------------------------------------------------- | ||
# | ||
# 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/orgpolicy/property/projectpolicy_alternate_spec_rules' | ||
module GoogleInSpec | ||
module Orgpolicy | ||
module Property | ||
class ProjectPolicyAlternateSpec | ||
attr_reader :update_time | ||
|
||
attr_reader :rules | ||
|
||
attr_reader :etag | ||
|
||
attr_reader :reset | ||
|
||
attr_reader :inherit_from_parent | ||
|
||
def initialize(args = nil, parent_identifier = nil) | ||
return if args.nil? | ||
@parent_identifier = parent_identifier | ||
@update_time = args['updateTime'] | ||
@rules = GoogleInSpec::Orgpolicy::Property::ProjectPolicyAlternateSpecRulesArray.parse(args['rules'], to_s) | ||
@etag = args['etag'] | ||
@reset = args['reset'] | ||
@inherit_from_parent = args['inheritFromParent'] | ||
end | ||
|
||
def to_s | ||
"#{@parent_identifier} ProjectPolicyAlternateSpec" | ||
end | ||
end | ||
end | ||
end | ||
end |
56 changes: 56 additions & 0 deletions
56
libraries/google/orgpolicy/property/projectpolicy_alternate_spec_rules.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# frozen_string_literal: false | ||
|
||
# ---------------------------------------------------------------------------- | ||
# | ||
# *** AUTO GENERATED CODE *** Type: MMv1 *** | ||
# | ||
# ---------------------------------------------------------------------------- | ||
# | ||
# 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/orgpolicy/property/projectpolicy_alternate_spec_rules_condition' | ||
require 'google/orgpolicy/property/projectpolicy_alternate_spec_rules_values' | ||
module GoogleInSpec | ||
module Orgpolicy | ||
module Property | ||
class ProjectPolicyAlternateSpecRules | ||
attr_reader :condition | ||
|
||
attr_reader :deny_all | ||
|
||
attr_reader :allow_all | ||
|
||
attr_reader :enforce | ||
|
||
attr_reader :values | ||
|
||
def initialize(args = nil, parent_identifier = nil) | ||
return if args.nil? | ||
@parent_identifier = parent_identifier | ||
@condition = GoogleInSpec::Orgpolicy::Property::ProjectPolicyAlternateSpecRulesCondition.new(args['condition'], to_s) | ||
@deny_all = args['denyAll'] | ||
@allow_all = args['allowAll'] | ||
@enforce = args['enforce'] | ||
@values = GoogleInSpec::Orgpolicy::Property::ProjectPolicyAlternateSpecRulesValues.new(args['values'], to_s) | ||
end | ||
|
||
def to_s | ||
"#{@parent_identifier} ProjectPolicyAlternateSpecRules" | ||
end | ||
end | ||
|
||
class ProjectPolicyAlternateSpecRulesArray | ||
def self.parse(value, parent_identifier) | ||
return if value.nil? | ||
return ProjectPolicyAlternateSpecRules.new(value, parent_identifier) unless value.is_a?(::Array) | ||
value.map { |v| ProjectPolicyAlternateSpecRules.new(v, parent_identifier) } | ||
end | ||
end | ||
end | ||
end | ||
end |
43 changes: 43 additions & 0 deletions
43
libraries/google/orgpolicy/property/projectpolicy_alternate_spec_rules_condition.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# frozen_string_literal: false | ||
|
||
# ---------------------------------------------------------------------------- | ||
# | ||
# *** AUTO GENERATED CODE *** Type: MMv1 *** | ||
# | ||
# ---------------------------------------------------------------------------- | ||
# | ||
# 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 Orgpolicy | ||
module Property | ||
class ProjectPolicyAlternateSpecRulesCondition | ||
attr_reader :title | ||
|
||
attr_reader :location | ||
|
||
attr_reader :expression | ||
|
||
attr_reader :description | ||
|
||
def initialize(args = nil, parent_identifier = nil) | ||
return if args.nil? | ||
@parent_identifier = parent_identifier | ||
@title = args['title'] | ||
@location = args['location'] | ||
@expression = args['expression'] | ||
@description = args['description'] | ||
end | ||
|
||
def to_s | ||
"#{@parent_identifier} ProjectPolicyAlternateSpecRulesCondition" | ||
end | ||
end | ||
end | ||
end | ||
end |
37 changes: 37 additions & 0 deletions
37
libraries/google/orgpolicy/property/projectpolicy_alternate_spec_rules_values.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# frozen_string_literal: false | ||
|
||
# ---------------------------------------------------------------------------- | ||
# | ||
# *** AUTO GENERATED CODE *** Type: MMv1 *** | ||
# | ||
# ---------------------------------------------------------------------------- | ||
# | ||
# 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 Orgpolicy | ||
module Property | ||
class ProjectPolicyAlternateSpecRulesValues | ||
attr_reader :denied_values | ||
|
||
attr_reader :allowed_values | ||
|
||
def initialize(args = nil, parent_identifier = nil) | ||
return if args.nil? | ||
@parent_identifier = parent_identifier | ||
@denied_values = args['deniedValues'] | ||
@allowed_values = args['allowedValues'] | ||
end | ||
|
||
def to_s | ||
"#{@parent_identifier} ProjectPolicyAlternateSpecRulesValues" | ||
end | ||
end | ||
end | ||
end | ||
end |
47 changes: 47 additions & 0 deletions
47
libraries/google/orgpolicy/property/projectpolicy_dry_run_spec.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# frozen_string_literal: false | ||
|
||
# ---------------------------------------------------------------------------- | ||
# | ||
# *** AUTO GENERATED CODE *** Type: MMv1 *** | ||
# | ||
# ---------------------------------------------------------------------------- | ||
# | ||
# 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/orgpolicy/property/projectpolicy_dry_run_spec_rules' | ||
module GoogleInSpec | ||
module Orgpolicy | ||
module Property | ||
class ProjectPolicyDryRunSpec | ||
attr_reader :update_time | ||
|
||
attr_reader :rules | ||
|
||
attr_reader :etag | ||
|
||
attr_reader :reset | ||
|
||
attr_reader :inherit_from_parent | ||
|
||
def initialize(args = nil, parent_identifier = nil) | ||
return if args.nil? | ||
@parent_identifier = parent_identifier | ||
@update_time = args['updateTime'] | ||
@rules = GoogleInSpec::Orgpolicy::Property::ProjectPolicyDryRunSpecRulesArray.parse(args['rules'], to_s) | ||
@etag = args['etag'] | ||
@reset = args['reset'] | ||
@inherit_from_parent = args['inheritFromParent'] | ||
end | ||
|
||
def to_s | ||
"#{@parent_identifier} ProjectPolicyDryRunSpec" | ||
end | ||
end | ||
end | ||
end | ||
end |
56 changes: 56 additions & 0 deletions
56
libraries/google/orgpolicy/property/projectpolicy_dry_run_spec_rules.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# frozen_string_literal: false | ||
|
||
# ---------------------------------------------------------------------------- | ||
# | ||
# *** AUTO GENERATED CODE *** Type: MMv1 *** | ||
# | ||
# ---------------------------------------------------------------------------- | ||
# | ||
# 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/orgpolicy/property/projectpolicy_dry_run_spec_rules_condition' | ||
require 'google/orgpolicy/property/projectpolicy_dry_run_spec_rules_values' | ||
module GoogleInSpec | ||
module Orgpolicy | ||
module Property | ||
class ProjectPolicyDryRunSpecRules | ||
attr_reader :condition | ||
|
||
attr_reader :deny_all | ||
|
||
attr_reader :allow_all | ||
|
||
attr_reader :enforce | ||
|
||
attr_reader :values | ||
|
||
def initialize(args = nil, parent_identifier = nil) | ||
return if args.nil? | ||
@parent_identifier = parent_identifier | ||
@condition = GoogleInSpec::Orgpolicy::Property::ProjectPolicyDryRunSpecRulesCondition.new(args['condition'], to_s) | ||
@deny_all = args['denyAll'] | ||
@allow_all = args['allowAll'] | ||
@enforce = args['enforce'] | ||
@values = GoogleInSpec::Orgpolicy::Property::ProjectPolicyDryRunSpecRulesValues.new(args['values'], to_s) | ||
end | ||
|
||
def to_s | ||
"#{@parent_identifier} ProjectPolicyDryRunSpecRules" | ||
end | ||
end | ||
|
||
class ProjectPolicyDryRunSpecRulesArray | ||
def self.parse(value, parent_identifier) | ||
return if value.nil? | ||
return ProjectPolicyDryRunSpecRules.new(value, parent_identifier) unless value.is_a?(::Array) | ||
value.map { |v| ProjectPolicyDryRunSpecRules.new(v, parent_identifier) } | ||
end | ||
end | ||
end | ||
end | ||
end |
Oops, something went wrong.