staypuft 0.3.1 → 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (40) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/javascripts/staypuft/nics_assignment.js +5 -5
  3. data/app/assets/javascripts/staypuft/staypuft.js +58 -5
  4. data/app/assets/javascripts/staypuft/subnets_assignment.js +5 -4
  5. data/app/assets/stylesheets/staypuft/bootstrap_and_overrides.css.scss +16 -0
  6. data/app/assets/stylesheets/staypuft/staypuft.css.scss +30 -71
  7. data/app/controllers/staypuft/deployments_controller.rb +23 -0
  8. data/app/controllers/staypuft/interface_assignments_controller.rb +2 -1
  9. data/app/lib/staypuft/network_query.rb +88 -5
  10. data/app/lib/staypuft/seeder.rb +75 -71
  11. data/app/models/staypuft/concerns/host_interface_management.rb +25 -2
  12. data/app/models/staypuft/concerns/subnet_ip_management.rb +17 -0
  13. data/app/models/staypuft/concerns/vip_nic_scopes.rb +13 -0
  14. data/app/models/staypuft/deployment/attribute_param_storage.rb +59 -1
  15. data/app/models/staypuft/deployment/cinder_service/equallogic.rb +80 -0
  16. data/app/models/staypuft/deployment/cinder_service.rb +53 -94
  17. data/app/models/staypuft/deployment/neutron_service.rb +20 -83
  18. data/app/models/staypuft/deployment/nova_service.rb +2 -31
  19. data/app/models/staypuft/deployment.rb +9 -7
  20. data/app/models/staypuft/subnet_type.rb +4 -0
  21. data/app/views/staypuft/deployments/_assigned_hosts.html.erb +23 -4
  22. data/app/views/staypuft/deployments/_deployment_access_all_details_dialogue.html.erb +5 -5
  23. data/app/views/staypuft/deployments/_deployment_hosts.html.erb +1 -1
  24. data/app/views/staypuft/deployments/_free_hosts.html.erb +4 -4
  25. data/app/views/staypuft/interface_assignments/index.html.erb +36 -31
  26. data/app/views/staypuft/interfaces/_drop_zone.html.erb +22 -22
  27. data/app/views/staypuft/steps/_cinder.html.erb +48 -26
  28. data/app/views/staypuft/steps/_cinder_equallogic_form.html.erb +13 -0
  29. data/app/views/staypuft/steps/_neutron.html.erb +0 -28
  30. data/app/views/staypuft/steps/_nova.html.erb +0 -11
  31. data/app/views/staypuft/steps/network_configuration.html.erb +27 -19
  32. data/app/views/staypuft/steps/services_configuration.html.erb +1 -1
  33. data/app/views/staypuft/subnet_typings/destroy.js.erb +1 -1
  34. data/app/views/staypuft/subnets/_drop_zone.html.erb +5 -5
  35. data/app/views/staypuft/subnets/_subnet_pull.html.erb +3 -4
  36. data/lib/staypuft/engine.rb +2 -0
  37. data/lib/staypuft/version.rb +1 -1
  38. metadata +6 -4
  39. data/app/models/staypuft/deployment/ips.rb +0 -25
  40. data/app/models/staypuft/deployment/vips.rb +0 -40
@@ -2,37 +2,42 @@
2
2
 
3
3
  <% title _("Configure Interfaces (%s hosts)") % @hosts.size %>
4
4
 
5
- <div id="subnets">
6
- <h2><%= _("Configured Networks") %></h2>
7
- <% @subnets.each do |subnet| %>
8
- <% next if is_pxe?(@deployment, subnet) # we skip PXE network which is always on primary interface %>
9
- <% next if @host.interfaces.where(:subnet_id => subnet.id).present? # we skip assigned subnets %>
10
- <%= render 'staypuft/subnets/subnet_pull',
11
- :subnet => subnet,
12
- :deployment => @deployment,
13
- :active => true,
14
- :existing => false %>
15
- <% end %>
5
+ <div class="row">
6
+ <div class="col-md-12">
7
+ <h3><%= _("Configured Networks") %></h3>
8
+ <div id="subnets" class="panel panel-default">
9
+ <div class="panel-body">
10
+ <% @subnets.each do |subnet| %>
11
+ <% next if is_pxe?(@deployment, subnet) # we skip PXE network which is always on primary interface %>
12
+ <% next if @host.interfaces.vip.where(:subnet_id => subnet.id).present? # we skip assigned subnets %>
13
+ <%= render 'staypuft/subnets/subnet_pull',
14
+ :subnet => subnet,
15
+ :deployment => @deployment,
16
+ :active => true,
17
+ :existing => false %>
18
+ <% end %>
19
+ </div>
20
+ </div>
21
+ </div>
16
22
  </div>
17
23
 
18
- <div class="cleared"></div>
19
- <br />
20
- <h2><%= _("Network Interfaces") %></h2>
24
+ <div class="row">
25
+ <div class="col-md-12">
26
+ <h3><%= _("Network Interfaces") %></h3>
27
+ <% if (subnet = @host.subnet) %>
28
+ <%= render 'staypuft/interfaces/drop_zone',
29
+ :identifier => @host.primary_interface,
30
+ :subnet => subnet,
31
+ :deployment => @deployment,
32
+ :host => @host %>
33
+ <% end %>
21
34
 
22
- <% if (subnet = @host.subnet) %>
23
- <%= render 'staypuft/interfaces/drop_zone',
24
- :identifier => @host.primary_interface,
25
- :subnet => subnet,
26
- :deployment => @deployment,
27
- :host => @host %>
28
- <% end %>
29
-
30
- <% @interfaces.each do |interface| %>
31
- <%= render 'staypuft/interfaces/drop_zone',
32
- :identifier => interface.identifier,
33
- :subnet => interface.subnet,
34
- :deployment => @deployment,
35
- :host => @host %>
36
- <% end %>
37
-
38
- <%= link_to _('Back to deployment'), deployment_path(@deployment) %>
35
+ <% @interfaces.each do |interface| %>
36
+ <%= render 'staypuft/interfaces/drop_zone',
37
+ :identifier => interface.identifier,
38
+ :subnet => interface.subnet,
39
+ :deployment => @deployment,
40
+ :host => @host %>
41
+ <% end %>
42
+ </div>
43
+ </div>
@@ -1,30 +1,30 @@
1
- <div class="interface" id="<%= identifier %>-interface" data-interface="<%= identifier %>">
2
- <div class="identifier">
3
- <%= identifier %>
1
+ <div class="panel panel-default interface" id="<%= identifier %>-interface" data-interface="<%= identifier %>">
2
+ <div class="panel-heading">
3
+ <h3 class="panel-title"><%= identifier %></h3>
4
4
  </div>
5
-
6
- <!-- physical interface assignment (can be only one at most) -->
7
- <div id="<%= identifier %>-physicals">
8
- <%= render 'staypuft/subnets/subnet_pull',
9
- :subnet => subnet,
10
- :deployment => deployment,
11
- :active => !is_pxe?(deployment, subnet),
12
- :existing => true if subnet %>
13
- </div>
14
-
15
- <!-- all virtual devices attached to this physical interface assignments -->
16
- <div id="<%= identifier %>-virtuals">
17
- <% host.interfaces.where(:physical_device => identifier).where("subnet_id IS NOT NULL").each do |virtual| %>
5
+ <div class="panel-body">
6
+ <!-- physical interface assignment (can be only one at most) -->
7
+ <span id="<%= identifier %>-physicals">
18
8
  <%= render 'staypuft/subnets/subnet_pull',
19
- :subnet => virtual.subnet,
9
+ :subnet => subnet,
20
10
  :deployment => deployment,
21
- :active => true,
22
- :existing => true if virtual.subnet %>
23
- <% end %>
24
- </div>
11
+ :active => !is_pxe?(deployment, subnet),
12
+ :existing => true if subnet %>
13
+ </span>
14
+
15
+ <!-- all virtual devices attached to this physical interface assignments -->
16
+ <span id="<%= identifier %>-virtuals">
17
+ <% host.interfaces.where(:physical_device => identifier).where("subnet_id IS NOT NULL").each do |virtual| %>
18
+ <%= render 'staypuft/subnets/subnet_pull',
19
+ :subnet => virtual.subnet,
20
+ :deployment => deployment,
21
+ :active => true,
22
+ :existing => true if virtual.subnet %>
23
+ <% end %>
24
+ </span>
25
25
 
26
- <div class="subnet-drop-zones">
27
26
  <div class="empty-zone">
27
+ &nbsp;
28
28
  </div>
29
29
  </div>
30
30
  </div>
@@ -1,30 +1,52 @@
1
- <%= f.fields_for :cinder, @deployment.cinder do |p| %>
2
- <%= field(p, :driver_backend, :label => _(Staypuft::Deployment::CinderService::DriverBackend::HUMAN)) do
3
- @deployment.cinder.backend_labels_for_layout.map do |value, label|
4
- radio_button_f_non_inline(p, :driver_backend,
5
- :checked => @deployment.cinder.driver_backend == value,
6
- :value => value,
7
- :text => label)
8
- end.join
9
- end %>
1
+ <div class="cinder">
2
+ <h5><%= _(Staypuft::Deployment::CinderService::DriverBackend::HUMAN) %></h5>
3
+ <div class="col-md-12 clearfix cinderPicker" id="cinderPicker">
4
+ <%= f.fields_for :cinder, @deployment.cinder do |p| %>
10
5
 
11
- <div class="cinder_nfs_uri col-md-offset-0 hide">
12
- <%= text_f p, :nfs_uri, class: "cinder_nfs_uri",
13
- label: _(Staypuft::Deployment::CinderService::NfsUri::HUMAN),
14
- help_inline: _(Staypuft::Deployment::CinderService::NfsUri::HUMAN_AFTER) %>
6
+ <%= check_box_f_non_inline(p, :backend_nfs,
7
+ :checked_value => 'true',
8
+ :unchecked_value => 'false',
9
+ :text => "NFS")
10
+ %>
11
+ <div class="cinder_nfs_uri col-md-offset-1 hide">
15
12
 
16
- </div>
17
- <div class="cinder_equallogic col-md-offset-0 hide">
18
- <%= text_f p, :san_ip, class: "cinder_equallogic",
19
- label: _(Staypuft::Deployment::CinderService::SanIp::HUMAN) %>
20
- <%= text_f p, :san_login, class: "cinder_equallogic",
21
- label: _(Staypuft::Deployment::CinderService::SanLogin::HUMAN) %>
22
- <%= text_f p, :san_password, class: "cinder_equallogic",
23
- label: _(Staypuft::Deployment::CinderService::SanPassword::HUMAN) %>
24
- <%= text_f p, :eqlx_pool, class: "cinder_equallogic",
25
- label: _(Staypuft::Deployment::CinderService::EqlxPool::HUMAN) %>
26
- <%= text_f p, :eqlx_group_name, class: "cinder_equallogic",
27
- label: _(Staypuft::Deployment::CinderService::EqlxGroupName::HUMAN) %>
13
+ <%= text_f p, :nfs_uri, class: "cinder_nfs_uri",
14
+ label: _(Staypuft::Deployment::CinderService::NfsUri::HUMAN),
15
+ help_inline: _(Staypuft::Deployment::CinderService::NfsUri::HUMAN_AFTER) %>
16
+
17
+ </div>
18
+
19
+ <%= check_box_f_non_inline(p, :backend_lvm,
20
+ :checked_value => 'true',
21
+ :unchecked_value => 'false',
22
+ :text => "LVM")
23
+ %>
28
24
 
25
+ <%= check_box_f_non_inline(p, :backend_ceph,
26
+ :checked_value => 'true',
27
+ :unchecked_value => 'false',
28
+ :text => "Ceph")
29
+ %>
30
+
31
+ <%= check_box_f_non_inline(p, :backend_eqlx,
32
+ :checked_value => 'true',
33
+ :unchecked_value => 'false',
34
+ :text => "EqualLogic")
35
+ %>
36
+ <div class="cinder_equallogic col-md-offset-1 hide">
37
+ <div id="eqlxs" class="cinder_equallogic_picker">
38
+ <% @deployment.cinder.eqlxs.each_with_index do |eqlx, index| %>
39
+ <%= p.fields_for "eqlxs[]", eqlx, index: index do |e| %>
40
+ <% render partial: 'cinder_equallogic_form', locals: {e: e} %>
41
+ <% end %>
42
+ <% end %>
43
+ </div>
44
+ <script type='html/template' id='eqlx_form_template'>
45
+ <%= p.fields_for 'eqlxs[]', Staypuft::Deployment::CinderService::Equallogic.new, index: 'NEW_RECORD' do |e| render(partial: 'cinder_equallogic_form', locals: {e: e}); end %>
46
+ </script>
47
+ <button type="button" class= "btn btn-primary btn-sm add_another_server"><%= _("Add Another Server") %></button>
48
+ </div>
49
+ <%end%>
29
50
  </div>
30
- <% end %>
51
+ </div>
52
+
@@ -0,0 +1,13 @@
1
+ <div class="eqlx well">
2
+ <h5 class="muted"><a href="#" class="remove"><i class="glyphicon glyphicon-remove-sign ">&nbsp;</i></a>&nbsp;Server #<span class="server_number">1</span></h5>
3
+ <%= text_f e, :san_ip, class: "cinder_equallogic",
4
+ label: _(Staypuft::Deployment::CinderService::SanIp::HUMAN) %>
5
+ <%= text_f e, :san_login, class: "cinder_equallogic",
6
+ label: _(Staypuft::Deployment::CinderService::SanLogin::HUMAN) %>
7
+ <%= text_f e, :san_password, class: "cinder_equallogic",
8
+ label: _(Staypuft::Deployment::CinderService::SanPassword::HUMAN) %>
9
+ <%= text_f e, :pool, class: "cinder_equallogic",
10
+ label: _(Staypuft::Deployment::CinderService::EqlxPool::HUMAN) %>
11
+ <%= text_f e, :group_name, class: "cinder_equallogic",
12
+ label: _(Staypuft::Deployment::CinderService::EqlxGroupName::HUMAN) %>
13
+ </div>
@@ -14,32 +14,4 @@
14
14
  help_inline: _(Staypuft::Deployment::NeutronService::TenantVlanRanges::HUMAN_AFTER)) %>
15
15
  </div>
16
16
 
17
- <h4><%= _('Network Nodes') %> </h4>
18
-
19
- <%= change_label_width 4, text_f(p, :networker_tenant_interface,
20
- label: _(Staypuft::Deployment::NeutronService::NetworkerTenantInterface::HUMAN),
21
- help_inline: _(Staypuft::Deployment::NeutronService::NetworkerTenantInterface::HUMAN_AFTER)) %>
22
-
23
- <%= check_box_f_non_inline(p, :use_external_interface,
24
- :checked_value => 'true',
25
- :unchecked_value => 'false',
26
- :text => Staypuft::Deployment::NeutronService::UseExternalInterface::HUMAN)
27
- %>
28
-
29
- <div class="neutron_external_interface col-md-offset-0 hide">
30
- <%= change_label_width 4, text_f(p, :external_interface_name,
31
- label: _(Staypuft::Deployment::NeutronService::ExternalInterfaceName::HUMAN),
32
- help_inline: _(Staypuft::Deployment::NeutronService::ExternalInterfaceName::HUMAN_AFTER)) %>
33
-
34
- </div>
35
-
36
-
37
- <h4><%= _('Compute Nodes') %> </h4>
38
-
39
- <%= change_label_width 4, text_f(p, :compute_tenant_interface,
40
- label: _(Staypuft::Deployment::NeutronService::ComputeTenantInterface::HUMAN),
41
- help_inline: _(Staypuft::Deployment::NeutronService::ComputeTenantInterface::HUMAN_AFTER)) %>
42
-
43
- <%= _('NOTE: Best practice is to use a different interface than the interface used for pxe/provisioning the node. This practice is mandatory if VLAN is chosen as the tenant network type.') %>
44
-
45
17
  <% end %>
@@ -20,15 +20,4 @@
20
20
  <%= change_label_width 4, text_f(p, :private_fixed_range,
21
21
  label: _(Staypuft::Deployment::NovaService::PrivateFixedRange::HUMAN),
22
22
  help_inline: _(Staypuft::Deployment::NovaService::PrivateFixedRange::HUMAN_AFTER)) %>
23
-
24
- <h4><%= _('Compute Nodes') %> </h4>
25
-
26
- <%= change_label_width 4, text_f(p, :external_interface_name, label: _(Staypuft::Deployment::NovaService::ExternalInterfaceName::HUMAN),
27
- help_inline: _(Staypuft::Deployment::NovaService::ExternalInterfaceName::HUMAN_AFTER)) %>
28
-
29
- <%= change_label_width 4, text_f(p, :compute_tenant_interface, label: _(Staypuft::Deployment::NovaService::ComputeTenantInterface::HUMAN),
30
- help_inline: _(Staypuft::Deployment::NovaService::ComputeTenantInterface::HUMAN_AFTER)) %>
31
-
32
- <%= _('NOTE: Best practice is to use a different interface than the interface used for pxe/provisioning the node. This practice is mandatory if VLAN is chosen as the tenant network type.') %>
33
-
34
23
  <% end %>
@@ -9,12 +9,16 @@
9
9
  </div>
10
10
 
11
11
  <div class="row">
12
- <div id="subnet_types" class="col-md-12">
12
+ <div class="col-md-12">
13
13
  <%= base_errors_for @deployment %>
14
- <h4><%= _("Available Roles") %></h4>
15
- <% @deployment.unassigned_subnet_types.each do |subnet_type| %>
16
- <%= render 'staypuft/subnet_types/subnet_type_pull', :subnet_type => subnet_type, :deployment => @deployment %>
17
- <% end %>
14
+ <h4><%= _("Available Network Traffic Types") %></h4>
15
+ <div id="subnet_types" class="panel panel-default">
16
+ <div class="panel-body">
17
+ <% @deployment.unassigned_subnet_types.each do |subnet_type| %>
18
+ <%= render 'staypuft/subnet_types/subnet_type_pull', :subnet_type => subnet_type, :deployment => @deployment %>
19
+ <% end %>
20
+ </div>
21
+ </div>
18
22
  </div>
19
23
  </div>
20
24
 
@@ -24,29 +28,33 @@
24
28
  <%= display_link_if_authorized(_("New Subnet"), hash_for_new_subnet_path(:redirect => request.url + '#new')) %>
25
29
  </div>
26
30
  </div>
31
+ </div>
27
32
 
33
+ <div class="row">
28
34
  <div id="subnets" class="col-md-12">
29
- <h4><%= _("Networks") %></h4>
35
+ <h4><%= _("Subnets") %></h4>
30
36
  <% @subnets.each do |subnet| %>
31
37
  <%= render 'staypuft/subnets/drop_zone', :subnet => subnet, :deployment => @deployment %>
32
38
  <% end %>
33
39
  </div>
34
40
  </div>
35
41
 
36
- <br />
37
-
38
- <%= form_for(@deployment, :url => wizard_path, :method => 'PUT', :html => {:class => ''}) do |f| %>
39
- <div class="form_actions">
40
- <a class="btn btn-default" href="<%= previous_wizard_path %>">
41
- <span class="glyphicon glyphicon-chevron-left"></span>
42
- <%= _("Back") %>
43
- </a>
44
- <%= link_to _("Cancel"), deployment_path(@deployment),
45
- :class => "btn btn-danger" %>
46
- <%= button_tag(:type => 'submit', :class => "btn btn-primary pull-right") do %>
47
- <%= _("Next") %>
42
+ <div class="row">
43
+ <div class="col-sm-12">
44
+ <%= form_for(@deployment, :url => wizard_path, :method => 'PUT', :html => {:class => ''}) do |f| %>
45
+ <div class="form_actions">
46
+ <a class="btn btn-default" href="<%= previous_wizard_path %>">
47
+ <span class="glyphicon glyphicon-chevron-left"></span>
48
+ <%= _("Back") %>
49
+ </a>
50
+ <%= link_to _("Cancel"), deployment_path(@deployment),
51
+ :class => "btn btn-danger" %>
52
+ <%= button_tag(:type => 'submit', :class => "btn btn-primary pull-right") do %>
53
+ <%= _("Next") %>
54
+ <% end %>
55
+ </div>
48
56
  <% end %>
49
57
  </div>
50
- <% end %>
58
+ </div>
51
59
  </div>
52
60
  <% end %>
@@ -14,7 +14,7 @@
14
14
  %>
15
15
  <li class="">
16
16
  <a href="#<%= service_name %>" data-toggle="tab">
17
- <%= service_name.capitalize %>
17
+ <%= service_name.capitalize %><span style="visibility: hidden" class ="glyphicon glyphicon-exclamation-sign" />
18
18
  </a>
19
19
  </li>
20
20
  <% end %>
@@ -1,6 +1,6 @@
1
1
  <% if @destroyed %>
2
2
  $('#<%= dom_id(@subnet_type) %>').remove();
3
- $("#subnet_types").append('<%=j render :partial => 'staypuft/subnet_types/subnet_type_pull',
3
+ $("#subnet_types .panel-body").append('<%=j render :partial => 'staypuft/subnet_types/subnet_type_pull',
4
4
  :object => @subnet_type,
5
5
  :locals => { :deployment => @deployment },
6
6
  :as => 'subnet_type' %>');
@@ -1,9 +1,9 @@
1
- <div class="subnet-drop-zone" id="<%= dom_id(subnet) %>_drop_zone" data-subnet-id="<%= subnet.id %>">
2
- <div class="name">
3
- <%= subnet.name %> - <%= subnet.network_address %>
1
+ <div class="subnet-drop-zone panel panel-default" id="<%= dom_id(subnet) %>_drop_zone" data-subnet-id="<%= subnet.id %>">
2
+ <div class="panel-heading">
3
+ <h3 class="panel-title"><%= subnet.name %> <small>- <%= subnet.network_address %></small></h3>
4
4
  </div>
5
5
 
6
- <div class="subnet-types">
6
+ <div class="panel-body subnet-types">
7
7
  <% deployment.subnet_typings.where(["#{Staypuft::SubnetTyping.table_name}.subnet_id = ?", subnet.id]).each do |typing| %>
8
8
  <%= render :partial => 'staypuft/subnet_types/subnet_type_pull',
9
9
  :object => typing.subnet_type,
@@ -11,6 +11,6 @@
11
11
  :as => :subnet_type %>
12
12
  <% end %>
13
13
 
14
- <div class="empty-zone"></div>
14
+ <div class="empty-zone">&nbsp;</div>
15
15
  </div>
16
16
  </div>
@@ -2,8 +2,7 @@
2
2
  id="<%= dom_id(subnet) %>"
3
3
  data-create-url="<%= deployment_interface_assignments_path(deployment, :host_ids => params[:host_ids], :subnet_id => subnet) %>"
4
4
  data-delete-url="<%= deployment_interface_assignment_path(deployment, 0, :host_ids => params[:host_ids], :subnet_id => subnet) %>">
5
- <div class="content">
6
- <div class="name"><%= subnet.name %> <%= '(vlan: ' + subnet.vlanid + ')' if subnet.vlanid.present? %></div>
7
- <div class="subnet-types"><%= subnet_types(deployment, subnet) %></div>
8
- </div>
5
+ <strong><%= subnet.name %> <%= '(vlan: ' + subnet.vlanid + ')' if subnet.vlanid.present? %></strong>
6
+ <br/>
7
+ <small class="text-muted"><%= subnet_types(deployment, subnet) %></small>
9
8
  </div>
@@ -33,6 +33,8 @@ module Staypuft
33
33
  ::Host::Managed.send :include, Staypuft::Concerns::HostDetailsHelper
34
34
  ::Host::Discovered.send :include, Staypuft::Concerns::HostOpenStackAffiliation
35
35
  ::Puppetclass.send :include, Staypuft::Concerns::PuppetclassExtensions
36
+ ::Nic::Base.send :include, Staypuft::Concerns::SubnetIpManagement
37
+ ::Nic::Base.send :include, Staypuft::Concerns::VipNicScopes
36
38
  ::Hostgroup.send :include, Staypuft::Concerns::HostgroupExtensions
37
39
  ::Environment.send :include, Staypuft::Concerns::EnvironmentExtensions
38
40
  ::LookupKey.send :include, Staypuft::Concerns::LookupKeyExtensions
@@ -1,3 +1,3 @@
1
1
  module Staypuft
2
- VERSION = '0.3.1'
2
+ VERSION = '0.3.2'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: staypuft
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Staypuft team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-09-03 00:00:00.000000000 Z
11
+ date: 2014-09-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: foreman-tasks
@@ -105,19 +105,20 @@ files:
105
105
  - app/models/staypuft/deployment/vlan_range_values_validator.rb
106
106
  - app/models/staypuft/deployment/nova_service.rb
107
107
  - app/models/staypuft/deployment/cinder_service.rb
108
- - app/models/staypuft/deployment/ips.rb
109
108
  - app/models/staypuft/deployment/abstract_param_scope.rb
109
+ - app/models/staypuft/deployment/cinder_service/equallogic.rb
110
110
  - app/models/staypuft/deployment/neutron_service.rb
111
111
  - app/models/staypuft/deployment/glance_service.rb
112
112
  - app/models/staypuft/deployment/attribute_param_storage.rb
113
- - app/models/staypuft/deployment/vips.rb
114
113
  - app/models/staypuft/deployment/passwords.rb
115
114
  - app/models/staypuft/service_class.rb
116
115
  - app/models/staypuft/subnet_type.rb
117
116
  - app/models/staypuft/layout.rb
117
+ - app/models/staypuft/concerns/vip_nic_scopes.rb
118
118
  - app/models/staypuft/concerns/hostgroup_extensions.rb
119
119
  - app/models/staypuft/concerns/puppetclass_extensions.rb
120
120
  - app/models/staypuft/concerns/host_details_helper.rb
121
+ - app/models/staypuft/concerns/subnet_ip_management.rb
121
122
  - app/models/staypuft/concerns/environment_extensions.rb
122
123
  - app/models/staypuft/concerns/host_interface_management.rb
123
124
  - app/models/staypuft/concerns/host_orchestration_build_hook.rb
@@ -153,6 +154,7 @@ files:
153
154
  - app/views/staypuft/steps/_neutron_non_ha.html.erb
154
155
  - app/views/staypuft/steps/services_overview.html.erb
155
156
  - app/views/staypuft/steps/network_configuration.html.erb
157
+ - app/views/staypuft/steps/_cinder_equallogic_form.html.erb
156
158
  - app/views/staypuft/steps/_nova_non_ha.html.erb
157
159
  - app/views/staypuft/steps/_title.html.erb
158
160
  - app/views/staypuft/steps/services_configuration.html.erb
@@ -1,25 +0,0 @@
1
- module Staypuft
2
- class Deployment::IPS < Deployment::AbstractParamScope
3
-
4
- class Jail < Safemode::Jail
5
- allow :controller_ip, :controller_ips, :controller_fqdns
6
- end
7
-
8
- def controllers
9
- @controllers ||= deployment.controller_hostgroup.hosts.order(:id)
10
- end
11
-
12
- def controller_ips
13
- controllers.map &:ip
14
- end
15
-
16
- def controller_fqdns
17
- controllers.map &:fqdn
18
- end
19
-
20
- def controller_ip
21
- controllers.tap { |v| v.size == 1 or raise }.first.ip
22
- end
23
-
24
- end
25
- end
@@ -1,40 +0,0 @@
1
- module Staypuft
2
- class Deployment::VIPS < Deployment::AbstractParamScope
3
-
4
- VIP_NAMES = [:ceilometer, :cinder, :db, :glance, :heat, :heat_cfn, :horizon, :keystone, :loadbalancer,
5
- :nova, :neutron, :amqp, :swift]
6
- COUNT = VIP_NAMES.size
7
-
8
- def self.param_scope
9
- 'vips'
10
- end
11
-
12
- param_attr :user_range
13
-
14
- HUMAN = N_('Virtual IP addresses range')
15
-
16
- class Jail < Safemode::Jail
17
- allow :get
18
- end
19
-
20
- def range
21
- (user_range || default_range)
22
- # TODO reserve the IP addresses
23
- end
24
-
25
- # TODO validate range that it is array with size 11 and that it contains only IPS
26
-
27
- def default_range
28
- @default_range ||= begin
29
- top_ip = hostgroup.subnet.to.split('.').map &:to_i
30
- ((top_ip[-1]-(COUNT-1))..top_ip[-1]).
31
- map { |last| [*top_ip[0..2], last] }.
32
- map { |ip| ip.join '.' }
33
- end
34
- end
35
-
36
- def get(name)
37
- range[VIP_NAMES.index(name) || raise(ArgumentError, "unknown #{name}")]
38
- end
39
- end
40
- end