class Google::Apis::ComputeV1::NetworkInterface
A network interface resource attached to an instance.
Attributes
An array of configurations for this interface. Currently, ONE_TO_ONE_NAT is the only access config supported. If there are no accessConfigs specified, then this instance will have no external internet access. Corresponds to the JSON property `accessConfigs` @return [Array<Google::Apis::ComputeV1::AccessConfig>]
- Output Only
-
The name of the network interface, generated by the server. For
network devices, these are eth0, eth1, etc. Corresponds to the JSON property `name` @return [String]
URL of the network resource for this instance. This is required for creating an instance but optional when creating a firewall rule. If not specified when creating a firewall rule, the default network is used: global/networks/default If you specify this property, you can specify the network as a full or partial URL. For example, the following are all valid URLs:
network
-
projects/project/global/networks/network
-
global/networks/default
Corresponds to the JSON property `network` @return [String]
- Output Only
-
An optional IPV4 internal network address assigned to the
instance for this network interface. Corresponds to the JSON property `networkIP` @return [String]
The URL of the Subnetwork resource for this instance. If the network resource is in legacy mode, do not provide this property. If the network is in auto subnet mode, providing the subnetwork is optional. If the network is in custom subnet mode, then this field should be specified. If you specify this property, you can specify the subnetwork as a full or partial URL. For example, the following are all valid URLs:
subnetworks/subnetwork
-
zones/zone/subnetworks/subnetwork
Corresponds to the JSON property `subnetwork` @return [String]
Public Class Methods
# File generated/google/apis/compute_v1/classes.rb, line 5288 def initialize(**args) update!(**args) end
Public Instance Methods
Update properties of this object
# File generated/google/apis/compute_v1/classes.rb, line 5293 def update!(**args) @access_configs = args[:access_configs] if args.key?(:access_configs) @name = args[:name] if args.key?(:name) @network = args[:network] if args.key?(:network) @network_ip = args[:network_ip] if args.key?(:network_ip) @subnetwork = args[:subnetwork] if args.key?(:subnetwork) end