Class: Google::Apis::DnsV1::Policy
- Inherits:
-
Object
- Object
- Google::Apis::DnsV1::Policy
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/dns_v1/classes.rb,
lib/google/apis/dns_v1/representations.rb,
lib/google/apis/dns_v1/representations.rb
Overview
A policy is a collection of DNS rules applied to one or more Virtual Private Cloud resources.
Instance Attribute Summary collapse
-
#alternative_name_server_config ⇒ Google::Apis::DnsV1::PolicyAlternativeNameServerConfig
Sets an alternative name server for the associated networks.
-
#description ⇒ String
A mutable string of at most 1024 characters associated with this resource for the user's convenience.
-
#dns64_config ⇒ Google::Apis::DnsV1::PolicyDns64Config
DNS64 policies Corresponds to the JSON property
dns64Config. -
#enable_inbound_forwarding ⇒ Boolean
(also: #enable_inbound_forwarding?)
Allows networks bound to this policy to receive DNS queries sent by VMs or applications over VPN connections.
-
#enable_logging ⇒ Boolean
(also: #enable_logging?)
Controls whether logging is enabled for the networks bound to this policy.
-
#id ⇒ Fixnum
Unique identifier for the resource; defined by the server (output only).
-
#kind ⇒ String
Corresponds to the JSON property
kind. -
#name ⇒ String
User-assigned name for this policy.
-
#networks ⇒ Array<Google::Apis::DnsV1::PolicyNetwork>
List of network names specifying networks to which this policy is applied.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Policy
constructor
A new instance of Policy.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Policy
Returns a new instance of Policy.
1628 1629 1630 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1628 def initialize(**args) update!(**args) end |
Instance Attribute Details
#alternative_name_server_config ⇒ Google::Apis::DnsV1::PolicyAlternativeNameServerConfig
Sets an alternative name server for the associated networks. When specified,
all DNS queries are forwarded to a name server that you choose. Names such as .
internal are not available when an alternative name server is specified.
Corresponds to the JSON property alternativeNameServerConfig
1580 1581 1582 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1580 def alternative_name_server_config @alternative_name_server_config end |
#description ⇒ String
A mutable string of at most 1024 characters associated with this resource for
the user's convenience. Has no effect on the policy's function.
Corresponds to the JSON property description
1586 1587 1588 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1586 def description @description end |
#dns64_config ⇒ Google::Apis::DnsV1::PolicyDns64Config
DNS64 policies
Corresponds to the JSON property dns64Config
1591 1592 1593 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1591 def dns64_config @dns64_config end |
#enable_inbound_forwarding ⇒ Boolean Also known as: enable_inbound_forwarding?
Allows networks bound to this policy to receive DNS queries sent by VMs or
applications over VPN connections. When enabled, a virtual IP address is
allocated from each of the subnetworks that are bound to this policy.
Corresponds to the JSON property enableInboundForwarding
1598 1599 1600 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1598 def enable_inbound_forwarding @enable_inbound_forwarding end |
#enable_logging ⇒ Boolean Also known as: enable_logging?
Controls whether logging is enabled for the networks bound to this policy.
Defaults to no logging if not set.
Corresponds to the JSON property enableLogging
1605 1606 1607 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1605 def enable_logging @enable_logging end |
#id ⇒ Fixnum
Unique identifier for the resource; defined by the server (output only).
Corresponds to the JSON property id
1611 1612 1613 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1611 def id @id end |
#kind ⇒ String
Corresponds to the JSON property kind
1616 1617 1618 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1616 def kind @kind end |
#name ⇒ String
User-assigned name for this policy.
Corresponds to the JSON property name
1621 1622 1623 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1621 def name @name end |
#networks ⇒ Array<Google::Apis::DnsV1::PolicyNetwork>
List of network names specifying networks to which this policy is applied.
Corresponds to the JSON property networks
1626 1627 1628 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1626 def networks @networks end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 |
# File 'lib/google/apis/dns_v1/classes.rb', line 1633 def update!(**args) @alternative_name_server_config = args[:alternative_name_server_config] if args.key?(:alternative_name_server_config) @description = args[:description] if args.key?(:description) @dns64_config = args[:dns64_config] if args.key?(:dns64_config) @enable_inbound_forwarding = args[:enable_inbound_forwarding] if args.key?(:enable_inbound_forwarding) @enable_logging = args[:enable_logging] if args.key?(:enable_logging) @id = args[:id] if args.key?(:id) @kind = args[:kind] if args.key?(:kind) @name = args[:name] if args.key?(:name) @networks = args[:networks] if args.key?(:networks) end |