Because this codename is used to reference the image type in imagefactory and in imagefactory the codename is 'vmware'
----- Original Message ----- From: "Michal Fojtik" mfojtik@redhat.com To: "Michal Fojtik" mfojtik@redhat.com Cc: aeolus-devel@lists.fedorahosted.org, "Francesco Vollero" fvollero@redhat.com, "Martyn Taylor" mtaylor@redhat.com Sent: Friday, 24 June, 2011 12:22:12 PM Subject: Re: [PATCH conductor] Added VMWare vSphere provider in seeds.rb and created a migration
On Jun 24, 2011, at 1:19 PM, Michal Fojtik wrote:
On Jun 24, 2011, at 12:46 PM, Martyn Taylor wrote:
Ack with One Small Nit:
You have left codename => 'vsphere' in the seeds
Please change this to 'vmware' and feel free to push
My obvious question on this is 'why'? :)
Deltacloud API driver name is 'vsphere', just because this driver speaks to vSphere SOAP. I think using 'vmware' is too generic.
A brief list of VMware virtualization products :-)
[snip] • VMware vSphere • VMware vCenter Operations • VMware vCloud Director • VMware vCenter Site Recovery Manager • VMware vCenter Product Family • VMware vShield Product Family • VMware vSphere Hypervisor (ESXi) [snip]
-- Michal
----- Original Message ----- From: "Francesco Vollero" fvollero@redhat.com To: aeolus-devel@lists.fedorahosted.org Sent: Thursday, 23 June, 2011 2:19:26 PM Subject: [PATCH conductor] Added VMWare vSphere provider in seeds.rb and created a migration
Signed-off-by: Francesco Vollero fvollero@redhat.com
...0110511120000_add_condor_cloud_provider_type.rb | 10 ++++++---- .../20110617105805_add_vmware_vsphere_provider.rb | 13 +++++++++++++ src/db/seeds.rb | 1 + 3 files changed, 20 insertions(+), 4 deletions(-) create mode 100644 src/db/migrate/20110617105805_add_vmware_vsphere_provider.rb
diff --git a/src/db/migrate/20110511120000_add_condor_cloud_provider_type.rb b/src/db/migrate/20110511120000_add_condor_cloud_provider_type.rb index 8d8dab5..d559e5d 100644 --- a/src/db/migrate/20110511120000_add_condor_cloud_provider_type.rb +++ b/src/db/migrate/20110511120000_add_condor_cloud_provider_type.rb @@ -1,13 +1,15 @@ class AddCondorCloudProviderType < ActiveRecord::Migration
def self.up
- provider_type = ProviderType.create!(:name => "CondorCloud", :build_supported => true, :codename =>"condorcloud")
- CredentialDefinition.create!(:name => 'username', :label => 'API Key', :input_type => 'text', :provider_type_id => provider_type.id)
- CredentialDefinition.create!(:name => 'password', :label => 'Secret', :input_type => 'password', :provider_type_id => provider_type.id)
- if not ProviderType.find_by_codename('condorcloud') and ProviderType.count > 0
provider_type = ProviderType.create!(:name => "CondorCloud", :build_supported => true, :codename =>"condorcloud")
CredentialDefinition.create!(:name => 'username', :label => 'API Key', :input_type => 'text', :provider_type_id => provider_type.id)
CredentialDefinition.create!(:name => 'password', :label => 'Secret', :input_type => 'password', :provider_type_id => provider_type.id)
- end
end
def self.down
- ProviderType.destroy_all(:codename =>"condorcloud")
end
end diff --git a/src/db/migrate/20110617105805_add_vmware_vsphere_provider.rb b/src/db/migrate/20110617105805_add_vmware_vsphere_provider.rb new file mode 100644 index 0000000..644a3ff --- /dev/null +++ b/src/db/migrate/20110617105805_add_vmware_vsphere_provider.rb @@ -0,0 +1,13 @@ +class AddVmwareVsphereProvider < ActiveRecord::Migration
- def self.up
- if not ProviderType.find_by_codename('vmware') and ProviderType.count > 0
provider_type = ProviderType.create!(:name => "VMWare vSphere", :build_supported => true, :codename =>"vmware")
CredentialDefinition.create!(:name => 'username', :label => 'Username', :input_type => 'text', :provider_type_id => provider_type.id)
CredentialDefinition.create!(:name => 'password', :label => 'Password', :input_type => 'password', :provider_type_id => provider_type.id)
- end
- end
- def self.down
- ProviderType.destroy_all(:codename=>"vmware")
- end
+end diff --git a/src/db/seeds.rb b/src/db/seeds.rb index eee6904..dee0a35 100644 --- a/src/db/seeds.rb +++ b/src/db/seeds.rb @@ -121,6 +121,7 @@ if ProviderType.all.empty? ProviderType.create!(:name => "RHEV-M", :codename =>"rhev-m") ProviderType.create!(:name => "OpenNebula", :codename =>"opennebula") ProviderType.create!(:name => "CondorCloud", :codename =>"condorcloud", :build_supported => 'true')
- ProviderType.create!(:name => "VMWare vSphere", :codename =>"vsphere", :build_supported => 'true')
end
# fill table CredentialDefinitions by default values
1.7.4.4
aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel _______________________________________________ aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel
Michal Fojtik, mfojtik@redhat.com Deltacloud API: http://deltacloud.org
aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel
------------------------------------------------------ Michal Fojtik, mfojtik@redhat.com Deltacloud API: http://deltacloud.org
_______________________________________________ aeolus-devel mailing list aeolus-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/aeolus-devel