Class: Google::Apis::ComputeAlpha::Host

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/compute_alpha/classes.rb,
generated/google/apis/compute_alpha/representations.rb,
generated/google/apis/compute_alpha/representations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ Host

Returns a new instance of Host



6714
6715
6716
# File 'generated/google/apis/compute_alpha/classes.rb', line 6714

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#creation_timestampString

[Output Only] Creation timestamp in RFC3339 text format. Corresponds to the JSON property creationTimestamp

Returns:

  • (String)


6633
6634
6635
# File 'generated/google/apis/compute_alpha/classes.rb', line 6633

def creation_timestamp
  @creation_timestamp
end

#descriptionString

[Output Only] An optional textual description of the resource. Corresponds to the JSON property description

Returns:

  • (String)


6638
6639
6640
# File 'generated/google/apis/compute_alpha/classes.rb', line 6638

def description
  @description
end

#host_typeString

Full or partial URL of the host type resource to use for this host, in the format: zones/zone/hostTypes/host-type. This is provided by the client when the host is created. For example, the following is a valid partial url to a predefined host type: zones/us-central1-b/hostTypes/n1-host-64-416 Corresponds to the JSON property hostType

Returns:

  • (String)


6647
6648
6649
# File 'generated/google/apis/compute_alpha/classes.rb', line 6647

def host_type
  @host_type
end

#idFixnum

[Output Only] The unique identifier for the resource. This identifier is defined by the server. Corresponds to the JSON property id

Returns:

  • (Fixnum)


6653
6654
6655
# File 'generated/google/apis/compute_alpha/classes.rb', line 6653

def id
  @id
end

#instancesArray<String>

A list of resource URLs to the virtual machine instances in this host. They must live in zones contained in the same region as this host. Corresponds to the JSON property instances

Returns:

  • (Array<String>)


6659
6660
6661
# File 'generated/google/apis/compute_alpha/classes.rb', line 6659

def instances
  @instances
end

#kindString

[Output Only] The type of the resource. Always compute#host for host. Corresponds to the JSON property kind

Returns:

  • (String)


6664
6665
6666
# File 'generated/google/apis/compute_alpha/classes.rb', line 6664

def kind
  @kind
end

#label_fingerprintString

A fingerprint for this request, which is essentially a hash of the metadata's contents and used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update metadata. You must always provide an up-to-date fingerprint hash in order to update or change metadata. To see the latest fingerprint, make get() request to the host. Corresponds to the JSON property labelFingerprint NOTE: Values are automatically base64 encoded/decoded in the client library.

Returns:

  • (String)


6675
6676
6677
# File 'generated/google/apis/compute_alpha/classes.rb', line 6675

def label_fingerprint
  @label_fingerprint
end

#labelsHash<String,String>

Labels to apply to this host. Corresponds to the JSON property labels

Returns:

  • (Hash<String,String>)


6680
6681
6682
# File 'generated/google/apis/compute_alpha/classes.rb', line 6680

def labels
  @labels
end

#nameString

The name of the resource, provided by the client when initially creating the resource. The resource name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression a-z? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. Corresponds to the JSON property name

Returns:

  • (String)


6690
6691
6692
# File 'generated/google/apis/compute_alpha/classes.rb', line 6690

def name
  @name
end

[Output Only] Server-defined URL for the resource. Corresponds to the JSON property selfLink

Returns:

  • (String)


6695
6696
6697
# File 'generated/google/apis/compute_alpha/classes.rb', line 6695

def self_link
  @self_link
end

#statusString

[Output Only] The status of the host. One of the following values: CREATING, READY, REPAIR, and DELETING. Corresponds to the JSON property status

Returns:

  • (String)


6701
6702
6703
# File 'generated/google/apis/compute_alpha/classes.rb', line 6701

def status
  @status
end

#status_messageString

[Output Only] An optional, human-readable explanation of the status. Corresponds to the JSON property statusMessage

Returns:

  • (String)


6706
6707
6708
# File 'generated/google/apis/compute_alpha/classes.rb', line 6706

def status_message
  @status_message
end

#zoneString

[Output Only] The name of the zone where the host resides, such as us-central1- a. Corresponds to the JSON property zone

Returns:

  • (String)


6712
6713
6714
# File 'generated/google/apis/compute_alpha/classes.rb', line 6712

def zone
  @zone
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



6719
6720
6721
6722
6723
6724
6725
6726
6727
6728
6729
6730
6731
6732
6733
# File 'generated/google/apis/compute_alpha/classes.rb', line 6719

def update!(**args)
  @creation_timestamp = args[:creation_timestamp] if args.key?(:creation_timestamp)
  @description = args[:description] if args.key?(:description)
  @host_type = args[:host_type] if args.key?(:host_type)
  @id = args[:id] if args.key?(:id)
  @instances = args[:instances] if args.key?(:instances)
  @kind = args[:kind] if args.key?(:kind)
  @label_fingerprint = args[:label_fingerprint] if args.key?(:label_fingerprint)
  @labels = args[:labels] if args.key?(:labels)
  @name = args[:name] if args.key?(:name)
  @self_link = args[:self_link] if args.key?(:self_link)
  @status = args[:status] if args.key?(:status)
  @status_message = args[:status_message] if args.key?(:status_message)
  @zone = args[:zone] if args.key?(:zone)
end