Sha256: 15b02e91ff173ed7c1b20c592f690c8eb3b229b58255575b4f5df5bbeb34fcb5
Contents?: true
Size: 1.89 KB
Versions: 1
Compression:
Stored size: 1.89 KB
Contents
#------------------------------------------------------------------------- # Copyright 2013 Microsoft Open Technologies, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. #-------------------------------------------------------------------------- module Azure module VirtualMachineManagement class VirtualMachine def initialize yield self if block_given? end attr_accessor :cloud_service_name attr_accessor :status attr_accessor :ipaddress attr_accessor :vm_name attr_accessor :udp_endpoints attr_accessor :hostname attr_accessor :deployment_name attr_accessor :deployment_status attr_accessor :tcp_endpoints attr_accessor :role_size attr_accessor :storage_account_name attr_accessor :password attr_accessor :vm_user attr_accessor :image attr_accessor :os_type attr_accessor :disk_name attr_accessor :virtual_network_name attr_accessor :virtual_network def cloud_service_name @cloud_service_name ||= (random_string(@vm_name+'-service-') if @vm_name) end def storage_account_name @storage_account_name ||= (random_string(@vm_name+'storage').gsub(/[^0-9a-z ]/i, '').downcase[0..23] if @vm_name) end def deployment_name @deployment_name ||= @cloud_service_name end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
azure-0.6.0 | lib/azure/virtual_machine_management/virtual_machine.rb |