Repo Freeze - fedorapeople.org testing repos
by steve linabery
Hello Aeolus Community,
While we test and prepare for release 0.7.0 of aeolus conductor and friends, the testing repos[0] are frozen and contain release candidate packages.
If you need to update any packages in the testing repos, please run it by me (irc: eggs) first, or raise it in #aeolus if I'm not available.
After we cut the actual release, we will build conductor, aeolus-configure, aeolus-cli, and aeolus-image-rubygem from master branches and update testing repos accordingly. Until then please build/install master branch code on a local basis.
Thank you!
Steve|eggs
[0] http://repos.fedorapeople.org/repos/aeolus/conductor/testing/
12 years, 4 months
[PATCH conductor] Redmine #2254: Always compile scss in dev enviroment.
by Jason Guiditta
https://www.aeolusproject.org/redmine/issues/2254
---
src/config/environments/development.rb | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/src/config/environments/development.rb b/src/config/environments/development.rb
index c8a77c2..21aeca8 100644
--- a/src/config/environments/development.rb
+++ b/src/config/environments/development.rb
@@ -43,4 +43,10 @@ Conductor::Application.configure do
# Otherwise we eat these connections even outside of tests:
WebMock.allow_net_connect! if defined?(WebMock)
+
+ Sass::Plugin.options.merge!(
+ :always_update => true,
+ :template_location => 'app/stylesheets',
+ :css_location => 'public/stylesheets/compiled'
+ )
end
--
1.7.6.4
12 years, 4 months
[PATCH aeolus-cli] Addedd provider acc. info to provider images
by Maros Zatko
From: Maros Zatko <mzatko(a)redhat.com>
---
lib/aeolus_cli/command/list_command.rb | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/lib/aeolus_cli/command/list_command.rb b/lib/aeolus_cli/command/list_command.rb
index fbc4ee4..b8b4c5f 100644
--- a/lib/aeolus_cli/command/list_command.rb
+++ b/lib/aeolus_cli/command/list_command.rb
@@ -70,7 +70,19 @@ module Aeolus
headers[:provider] = "Provider"
headers[:status] = "Status"
headers[:target_image] = "Target Image"
+ headers[:account_name] = "Provider Name"
+ headers[:account_type] = "Provider Type"
collection = @options[:id].nil? ? Aeolus::CLI::ProviderImage.all : Aeolus::CLI::ProviderImage.find(:all, :from => Aeolus::CLI::Base.site.path + "/target_images/" + @options[:id] + "/provider_images.xml")
+
+ paccs = Aeolus::CLI::ProviderAccount.all.group_by(&:provider)
+
+ collection.map do |item|
+ prov = item.attributes[:provider]
+ item.attributes[:account_name] = paccs[prov].first.name
+ item.attributes[:account_type] = paccs[prov].first.provider_type
+ item
+ end
+
print_collection(collection, headers)
quit(0)
rescue => e
--
1.7.7.3
12 years, 4 months
[PATCH conductor] Deploaybles and catalog_entries cleanups
by Jan Provazník
From: Jan Provaznik <jprovazn(a)redhat.com>
This is first try to cleanup deploayble/catalog_entries rename.
TODO: rename locale messages (will be probably separate patch).
---
src/app/controllers/catalog_entries_controller.rb | 13 +--
src/app/controllers/catalogs_controller.rb | 2 +-
src/app/controllers/deployables_controller.rb | 117 ++++++++++----------
src/app/controllers/images_controller.rb | 2 +-
src/app/models/catalog_entry.rb | 15 ---
src/app/models/deployable.rb | 20 +++-
src/app/views/catalogs/show.html.haml | 28 +++---
src/app/views/deployables/_form.html.haml | 35 +++---
src/app/views/deployables/_from_url.html.haml | 21 ++--
src/app/views/deployables/_list.html.haml | 14 +-
.../views/deployables/_new_from_image.html.haml | 14 +-
src/app/views/deployables/_upload.html.haml | 29 +++---
src/app/views/deployables/edit.html.haml | 8 +-
src/app/views/deployables/show.html.haml | 14 +-
src/config/locales/en.yml | 3 +
src/features/deployables.feature | 18 ++--
src/features/step_definitions/deployable_steps.rb | 12 +--
.../controllers/deployables_controller_spec.rb | 2 +-
18 files changed, 179 insertions(+), 188 deletions(-)
diff --git a/src/app/controllers/catalog_entries_controller.rb b/src/app/controllers/catalog_entries_controller.rb
index 1d454eb..8f8d9ea 100644
--- a/src/app/controllers/catalog_entries_controller.rb
+++ b/src/app/controllers/catalog_entries_controller.rb
@@ -24,10 +24,10 @@ class CatalogEntriesController < ApplicationController
require_privilege(Privilege::MODIFY, @catalog_entry.deployable)
if @catalog_entry.save
- redirect_to catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry), :notice => t('catalog_entries.flash.notice.added')
+ redirect_to catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry.deployable), :notice => t('catalog_entries.flash.notice.added')
else
flash[:warning] = t('catalog_entries.flash.warning.failed')
- redirect_to catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry.deployable.catalog_entries.first)
+ redirect_to catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry.deployable)
end
end
@@ -39,14 +39,7 @@ class CatalogEntriesController < ApplicationController
require_privilege(Privilege::MODIFY, @catalog_entry.catalog)
require_privilege(Privilege::MODIFY, @catalog_entry.deployable)
@catalog_entry.destroy
-
- if deployable.catalog_entries.empty?
- redirect_to catalog_path(catalog), :notice => t('catalog_entries.flash.notice.deleted')
- else
- catalog_entry_to_nagigate = deployable.catalog_entries.first
- redirect_to catalog_deployable_path(catalog_entry_to_nagigate.catalog, catalog_entry_to_nagigate), :notice => t('catalog_entries.flash.notice.deleted')
- end
-
+ redirect_to catalog_deployable_path(catalog, deployable), :notice => t('catalog_entries.flash.notice.deleted')
end
end
diff --git a/src/app/controllers/catalogs_controller.rb b/src/app/controllers/catalogs_controller.rb
index 6957d1c..8a3d6cd 100644
--- a/src/app/controllers/catalogs_controller.rb
+++ b/src/app/controllers/catalogs_controller.rb
@@ -39,7 +39,7 @@ class CatalogsController < ApplicationController
def show
@catalog = Catalog.find(params[:id])
- @catalog_entries = @catalog.catalog_entries.apply_filters(:preset_filter_id => params[:catalog_entries_preset_filter], :search_filter => params[:catalog_entries_search])
+ @deployables = @catalog.deployables.apply_filters(:preset_filter_id => params[:catalog_entries_preset_filter], :search_filter => params[:catalog_entries_search])
require_privilege(Privilege::VIEW, @catalog)
save_breadcrumb(catalogs_path(@catalog), @catalog.name)
@header = [
diff --git a/src/app/controllers/deployables_controller.rb b/src/app/controllers/deployables_controller.rb
index c5e7a4e..a1d7f9b 100644
--- a/src/app/controllers/deployables_controller.rb
+++ b/src/app/controllers/deployables_controller.rb
@@ -23,21 +23,21 @@ class DeployablesController < ApplicationController
def index
clear_breadcrumbs
save_breadcrumb(catalog_deployables_path(:viewstate => @viewstate ? @viewstate.id : nil))
- @deployables = Deployable.list_for_user(current_user, Privilege::VIEW)
+ @catalog = Catalog.find(params[:catalog_id])
+ @deployables = @catalog.deployables
@catalog_entries = @deployables.collect { |d| d.catalog_entries.first }
#@catalog_entries = CatalogEntry.list_for_user(current_user, Privilege::VIEW).apply_filters(:preset_filter_id => params[:catalog_entries_preset_filter], :search_filter => params[:catalog_entries_search])
- @catalog = @catalog_entries.first.catalog unless @catalog_entries.empty?
set_header
end
def new
- @catalog_entry = params[:catalog_entry].nil? ? CatalogEntry.new() : CatalogEntry.new(params[:catalog_entry])
- @catalog_entry.deployable = Deployable.new unless @catalog_entry.deployable
+ @deployable = Deployable.new(params[:deployable])
require_privilege(Privilege::CREATE, Deployable)
if params[:create_from_image]
@image = Aeolus::Image::Warehouse::Image.find(params[:create_from_image])
@hw_profiles = HardwareProfile.frontend.list_for_user(current_user, Privilege::VIEW)
- @catalog_entry.deployable.name = @image.name
+ @deployable.name = @image.name
+ @selected_catalogs = params[:catalog_id].to_a
load_catalogs
else
@catalog = Catalog.find(params[:catalog_id])
@@ -51,13 +51,14 @@ class DeployablesController < ApplicationController
end
def show
- @catalog_entry = CatalogEntry.find(params[:id])
- require_privilege(Privilege::VIEW, @catalog_entry.deployable)
- save_breadcrumb(catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry), @catalog_entry.deployable.name)
+ @deployable = Deployable.find(params[:id])
+ @catalog = Catalog.find(params[:catalog_id])
+ require_privilege(Privilege::VIEW, @deployable)
+ save_breadcrumb(catalog_deployable_path(@catalog, @deployable), @deployable.name)
@providers = Provider.all
- @catalogs_options = Catalog.all.map {|c| [c.name, c.id] unless c == @catalog_entry.catalog}.compact
- add_permissions_inline((a)catalog_entry.deployable)
- @image_details = @catalog_entry.deployable.get_image_details
+ @catalogs_options = Catalog.all.map {|c| [c.name, c.id] unless c == @catalog}.compact
+ add_permissions_inline(@deployable)
+ @image_details = @deployable.get_image_details
@image_details.each do |assembly|
assembly.keys.each do |key|
flash[:error] = assembly[key] if key.to_s =~ /^error\w+/
@@ -71,69 +72,70 @@ class DeployablesController < ApplicationController
return
end
-
- @catalog_entry = CatalogEntry.new(params[:catalog_entry])
- if params[:create_from_image].present?
- @catalog = @catalog_entry.catalog
- @catalog_entry.deployable = Deployable.new unless @catalog_entry.deployable
- else
- @catalog = Catalog.find(params[:catalog_id])
- @catalog_entry.catalog = @catalog
- end
- require_privilege(Privilege::MODIFY, @catalog)
require_privilege(Privilege::CREATE, Deployable)
- @catalog_entry.deployable.owner = current_user
+ @deployable = Deployable.new(params[:deployable])
+ @selected_catalogs = Catalog.find(params[:catalog_id]).to_a
+ @deployable.owner = current_user
if params.has_key? :url
xml = import_xml_from_url(params[:url])
unless xml.nil?
#store xml_filename for url (i.e. url ends to: foo || foo.xml)
- @catalog_entry.deployable.xml_filename = File.basename(URI.parse(params[:url]).path)
- @catalog_entry.deployable.xml = xml
+ @deployable.xml_filename = File.basename(URI.parse(params[:url]).path)
+ @deployable.xml = xml
end
elsif params[:create_from_image].present?
hw_profile = HardwareProfile.frontend.find(params[:hardware_profile])
require_privilege(Privilege::VIEW, hw_profile)
- @catalog_entry.deployable.set_from_image(params[:create_from_image], hw_profile)
+ @deployable.set_from_image(params[:create_from_image], hw_profile)
end
- if @catalog_entry.save
- flash[:notice] = t "catalog_entries.flash.notice.added"
- if params[:edit_xml]
- redirect_to edit_catalog_deployable_path @catalog_entry.catalog.id, @catalog_entry.id, :edit_xml =>true
- else
- redirect_to catalog_deployables_path(@catalog)
+ begin
+ raise t("deployables.flash.error.no_catalog") if @selected_catalogs.empty?
+ @deployable.transaction do
+ @deployable.save!
+ @selected_catalogs.each do |catalog|
+ require_privilege(Privilege::MODIFY, catalog)
+ CatalogEntry.create!(:catalog_id => catalog.id, :deployable_id => @deployable.id)
+ end
+ flash[:notice] = t "catalog_entries.flash.notice.added"
+ if params[:edit_xml]
+ redirect_to edit_catalog_deployable_path @selected_catalogs.first, @deployable.id, :edit_xml =>true
+ else
+ redirect_to catalog_deployables_path((a)selected_catalogs.first)
+ end
end
- else
- flash[:warning]= t('catalog_entries.flash.warning.not_valid') if @catalog_entry.errors.has_key?(:xml)
+ rescue => e
+ flash[:warning]= t('deployables.flash.warning.failed', :message => e.message)
+ flash[:warning]= t('catalog_entries.flash.warning.not_valid') if @deployable.errors.has_key?(:xml)
if params[:create_from_image].present?
load_catalogs
@image = Aeolus::Image::Warehouse::Image.find(params[:create_from_image])
@hw_profiles = HardwareProfile.frontend.list_for_user(current_user, Privilege::VIEW)
- @catalog_entry.deployable.name = @image.name
+ @deployable.name = @image.name
else
+ @catalog = @selected_catalogs.first
params.delete(:edit_xml) if params[:edit_xml]
- @form_option = params[:catalog_entry].has_key?(:xml) ? 'upload' : 'from_url'
- @form_option = params[:catalog_entry][:deployable].has_key?(:xml) ? 'upload' : 'from_url'
+ @form_option = params[:deployable].has_key?(:xml) ? 'upload' : 'from_url'
end
render :new
end
end
def edit
- @catalog_entry = CatalogEntry.find(params[:id])
- require_privilege(Privilege::MODIFY, @catalog_entry.deployable)
- @catalog = @catalog_entry.catalog
+ @deployable = Deployable.find(params[:id])
+ require_privilege(Privilege::MODIFY, @deployable)
+ @catalog = Catalog.find(params[:catalog_id])
end
def update
- @catalog_entry = CatalogEntry.find(params[:id])
- require_privilege(Privilege::MODIFY, @catalog_entry.deployable)
- params[:catalog_entry][:deployable].delete(:owner_id) if params[:catalog_entry] and params[:catalog_entry][:deployable]
+ @deployable = Deployable.find(params[:id])
+ require_privilege(Privilege::MODIFY, @deployable)
+ params[:deployable].delete(:owner_id) if params[:deployable]
- if @catalog_entry.update_attributes(params[:catalog_entry])
+ if @deployable.update_attributes(params[:deployable])
flash[:notice] = t"catalog_entries.flash.notice.updated"
- redirect_to catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry)
+ redirect_to catalog_deployable_path(params[:catalog_id], @deployable)
else
render :action => 'edit'
end
@@ -141,28 +143,25 @@ class DeployablesController < ApplicationController
def multi_destroy
@catalog = nil
- CatalogEntry.find(params[:catalog_entries_selected]).to_a.each do |d|
- require_privilege(Privilege::MODIFY, d.catalog)
- require_privilege(Privilege::MODIFY, d.deployable)
- @catalog = d.catalog
- # Don't do this when we're managing deployables independently
- d.deployable.destroy
+ Deployable.find(params[:deployables_selected]).to_a.each do |d|
+ # TODO: delete only in catalogs where I have permission to
+ #require_privilege(Privilege::MODIFY, d.catalog)
+ require_privilege(Privilege::MODIFY, d)
+ #@catalog = d.catalog
d.destroy
end
- redirect_to catalog_path(@catalog)
+ redirect_to catalog_path(params[:catalog_id])
end
def destroy
- catalog_entry = CatalogEntry.find(params[:id])
- require_privilege(Privilege::MODIFY, catalog_entry.catalog)
- require_privilege(Privilege::MODIFY, catalog_entry.deployable)
- @catalog = catalog_entry.catalog
- # Don't do this when we're managing deployables independently
- catalog_entry.deployable.destroy
- catalog_entry.destroy
+ deployable = Deployable.find(params[:id])
+ # TODO: delete only in catalogs where I have permission to
+ #require_privilege(Privilege::MODIFY, catalog_entry.catalog)
+ require_privilege(Privilege::MODIFY, deployable)
+ deployable.destroy
respond_to do |format|
- format.html { redirect_to catalog_path(@catalog) }
+ format.html { redirect_to catalog_path(params[:catalog_id]) }
end
end
diff --git a/src/app/controllers/images_controller.rb b/src/app/controllers/images_controller.rb
index 3560640..e951059 100644
--- a/src/app/controllers/images_controller.rb
+++ b/src/app/controllers/images_controller.rb
@@ -172,7 +172,7 @@ class ImagesController < ApplicationController
})
flash.now[:error] = t('images.flash.notice.created')
if params[:make_deployable]
- redirect_to new_catalog_entry_path(:create_from_image => @image.id)
+ redirect_to new_deployable_path(:create_from_image => @image.id)
else
redirect_to image_path((a)image.id)
end
diff --git a/src/app/models/catalog_entry.rb b/src/app/models/catalog_entry.rb
index 21a8b9b..2ea3a3c 100644
--- a/src/app/models/catalog_entry.rb
+++ b/src/app/models/catalog_entry.rb
@@ -29,10 +29,6 @@
#
class CatalogEntry < ActiveRecord::Base
- class << self
- include CommonFilterMethods
- end
-
belongs_to :catalog
belongs_to :deployable
@@ -43,15 +39,4 @@ class CatalogEntry < ActiveRecord::Base
# This probably goes away once we separate catalog entry creation from deployables
accepts_nested_attributes_for :deployable
- PRESET_FILTERS_OPTIONS = []
-
- private
-
- def self.apply_search_filter(search)
- if search
- where("name ILIKE :search", :search => "%#{search}%")
- else
- scoped
- end
- end
end
diff --git a/src/app/models/deployable.rb b/src/app/models/deployable.rb
index be553e7..2a568ac 100644
--- a/src/app/models/deployable.rb
+++ b/src/app/models/deployable.rb
@@ -17,6 +17,11 @@
# also available at http://www.gnu.org/copyleft/gpl.html.
class Deployable < ActiveRecord::Base
+ class << self
+ include CommonFilterMethods
+ end
+
+
include PermissionedObject
validates_presence_of :name
@@ -29,12 +34,14 @@ class Deployable < ActiveRecord::Base
has_many :permissions, :as => :permission_object, :dependent => :destroy,
:include => [:role],
:order => "permissions.id ASC"
- has_many :catalog_entries
+ has_many :catalog_entries, :dependent => :destroy
has_many :catalogs, :through => :catalog_entries
belongs_to :owner, :class_name => "User", :foreign_key => "owner_id"
after_create "assign_owner_roles(owner)"
+ PRESET_FILTERS_OPTIONS = []
+
def valid_deployable_xml?
deployable_xml = DeployableXML.new(xml)
unless deployable_xml.validate!
@@ -135,4 +142,15 @@ class Deployable < ActiveRecord::Base
#returned value [{:name => 'assembly1',{:hwp => {...}}, {:error => "msg"}, {assembly3} ..]
result_array
end
+
+ private
+
+ def self.apply_search_filter(search)
+ if search
+ where("name ILIKE :search", :search => "%#{search}%")
+ else
+ scoped
+ end
+ end
+
end
diff --git a/src/app/views/catalogs/show.html.haml b/src/app/views/catalogs/show.html.haml
index 1dd4259..b4433f8 100644
--- a/src/app/views/catalogs/show.html.haml
+++ b/src/app/views/catalogs/show.html.haml
@@ -21,33 +21,33 @@
.content
- content_for :form_header do
%li= restful_submit_tag t("delete"), "destroy", multi_destroy_catalog_deployables_path(@catalog), 'DELETE', :id => 'delete_button', :class => 'button danger'
- %li= link_to t("catalog_entries.new_catalog_entry"), new_catalog_deployable_path(@catalog), :class => 'button', :id => 'new_catalog_entry_button'
+ %li= link_to t("catalog_entries.new_catalog_entry"), new_catalog_deployable_path(@catalog), :class => 'button', :id => 'new_deployablesutton'
- content_for :filter_controls do
%li
- = label_tag :catalog_entries_preset_filter, t('filter_table.viewing')
+ = label_tag :deployables_preset_filter, t('filter_table.viewing')
= hidden_field_tag :current_path, request.fullpath
- = select_tag(:catalog_entries_preset_filter, preset_filters_options_for_select(CatalogEntry::PRESET_FILTERS_OPTIONS, params[:catalog_entries_preset_filter]), :include_blank => t("catalog_entries.preset_filters.all_catalog_entries"), :disabled => true)
- = restful_submit_tag t("filter_table.apply_filters"), "filter", filter_catalog_deployables_path(@catalog), 'POST', :class => 'button', :id => 'apply_catalog_entries_preset_filter'
- %span.label.badge.dark= @catalog_entries.count
+ = select_tag(:deployables_preset_filter, preset_filters_options_for_select(Deployable::PRESET_FILTERS_OPTIONS, params[:deployables_preset_filter]), :include_blank => t("catalog_entries.preset_filters.all_catalog_entries"), :disabled => true)
+ = restful_submit_tag t("filter_table.apply_filters"), "filter", filter_catalog_deployables_path(@catalog), 'POST', :class => 'button', :id => 'apply_deployables_preset_filter'
+ %span.label.badge.dark= @deployables.count
%li.table-search-filter
- = text_field_tag :catalog_entries_search, params[:catalog_entries_search], :placeholder => t("filter_table.search")
- = restful_submit_tag "", "search", filter_catalog_deployables_path(@catalog), 'POST', :class => 'button', :id => 'apply_catalog_entries_search'
+ = text_field_tag :deployables_search, params[:deployables_search], :placeholder => t("filter_table.search")
+ = restful_submit_tag "", "search", filter_catalog_deployables_path(@catalog), 'POST', :class => 'button', :id => 'apply_deployables_search'
:javascript
$(document).ready(function(){
- $("#apply_catalog_entries_preset_filter").hide();
- $("#catalog_entries_preset_filter").change(function() {
- $("#apply_catalog_entries_preset_filter").click();
+ $("#apply_deployables_preset_filter").hide();
+ $("#deployables_preset_filter").change(function() {
+ $("#apply_deployables_preset_filter").click();
});
});
- = filter_table(@header, @catalog_entries) do |catalog_entry|
+ = filter_table(@header, @deployables) do |deployable|
%tr{:class => cycle('nostripe','stripe')}
%td{:class => 'checkbox'}
- selected = params[:select] == 'all'
- = check_box_tag "catalog_entries_selected[]", catalog_entry.id, selected, :id => "catalog_entry_checkbox_#{catalog_entry.id}"
+ = check_box_tag "deployables_selected[]", deployable.id, selected, :id => "deployable_checkbox_#{deployable.id}"
%td
- = link_to catalog_entry.deployable.name, catalog_deployable_path(@catalog, catalog_entry)
+ = link_to deployable.name, catalog_deployable_path(@catalog, deployable)
%td
- = link_to catalog_entry.deployable.xml_filename, catalog_deployable_path(@catalog, catalog_entry, :deployable_xml => true)
+ = link_to deployable.xml_filename, catalog_deployable_path(@catalog, deployable, :deployable_xml => true)
diff --git a/src/app/views/deployables/_form.html.haml b/src/app/views/deployables/_form.html.haml
index d638684..fa6ec32 100644
--- a/src/app/views/deployables/_form.html.haml
+++ b/src/app/views/deployables/_form.html.haml
@@ -1,26 +1,25 @@
-- if @catalog_entry.errors.any?
- = render 'layouts/error_messages', :object => @catalog_entry
+- if @deployable.errors.any?
+ = render 'layouts/error_messages', :object => @deployable
%fieldset
- - if params[:edit_xml]
- = form.fields_for :deployable, @catalog_entry.deployable do |deployable_fields|
+ = form_for @deployable do |form|
+ - if params[:edit_xml]
%p
- = deployable_fields.label :xml, t('.deployable_xml')
- = deployable_fields.text_area :xml, :class => 'long'
- - else
- %p
- = form.label :catalog_id, t('catalog_entries.form.catalog')
- = @catalog ? @catalog.name : @catalog_entry.catalog.name
- .clear
- = form.fields_for :deployable, @catalog_entry.deployable do |deployable_fields|
+ = form.label :xml, t('.deployable_xml')
+ = form.text_area :xml, :class => 'long'
+ - else
%p
- = deployable_fields.label :name, t('catalog_entries.index.name')
- = deployable_fields.text_field :name, :class => 'em long'
+ = label_tag :catalog_id, t('catalog_entries.form.catalog')
+ = @catalog.name
+ .clear
%p
- = deployable_fields.label :description, t('.description')
- = deployable_fields.text_area :description, :class => 'long'
+ = form.label :name, t('catalog_entries.index.name')
+ = form.text_field :name, :class => 'em long'
%p
- = deployable_fields.label :xml, t('.deployable_xml')
- = link_to t("catalog_entries.properties.edit_deployable_xml"), edit_catalog_deployable_path((a)catalog_entry.catalog.id, @catalog_entry.id, :edit_xml=>true)
+ = form.label :description, t('.description')
+ = form.text_area :description, :class => 'long'
+ %p
+ = form.label :xml, t('.deployable_xml')
+ = link_to t("catalog_entries.properties.edit_deployable_xml"), edit_catalog_deployable_path((a)catalog.id, @deployable.id, :edit_xml=>true)
%fieldset.options
= link_to t('cancel'), catalog_path(@catalog), :class => 'button danger'
diff --git a/src/app/views/deployables/_from_url.html.haml b/src/app/views/deployables/_from_url.html.haml
index 22b0099..d351ecb 100644
--- a/src/app/views/deployables/_from_url.html.haml
+++ b/src/app/views/deployables/_from_url.html.haml
@@ -1,19 +1,18 @@
-= form_for @catalog_entry, :url => catalog_deployables_path(@catalog), :html => {:class => 'generic', :multipart => true } do |form|
- - if @catalog_entry.errors.any?
- = render 'layouts/error_messages', :object => @catalog_entry
+= form_for @deployable, :url => catalog_deployables_path(@catalog), :html => {:class => 'generic', :multipart => true } do |form|
+ - if @deployable.errors.any?
+ = render 'layouts/error_messages', :object => @deployable
%fieldset
%p
= form.label :catalog_id, t('catalog_entries.form.catalog')
%span.text_instead_input= @catalog.name
.clear
- =form.fields_for :deployable, @catalog_entry.deployable do |deployable_fields|
- %fieldset
- %p
- = deployable_fields.label :name, t('catalog_entries.index.name')
- = deployable_fields.text_field :name, :class => 'em long'
- %p
- = deployable_fields.label :description, t('catalog_entries.form.description')
- = deployable_fields.text_area :description, :class => 'long'
+ %fieldset
+ %p
+ = form.label :name, t('catalog_entries.index.name')
+ = form.text_field :name, :class => 'em long'
+ %p
+ = form.label :description, t('catalog_entries.form.description')
+ = form.text_area :description, :class => 'long'
%fieldset
%p
= label_tag :url, t('catalog_entries.form.deployable_xml_url')
diff --git a/src/app/views/deployables/_list.html.haml b/src/app/views/deployables/_list.html.haml
index 117e636..55bf664 100644
--- a/src/app/views/deployables/_list.html.haml
+++ b/src/app/views/deployables/_list.html.haml
@@ -10,9 +10,9 @@
%li
= label_tag :catalog_entries_preset_filter, t('filter_table.viewing')
= hidden_field_tag :current_path, request.fullpath
- = select_tag(:catalog_entries_preset_filter, preset_filters_options_for_select(CatalogEntry::PRESET_FILTERS_OPTIONS, params[:catalog_entries_preset_filter]), :include_blank => t("catalog_entries.preset_filters.all_catalog_entries"), :disabled => true)
+ = select_tag(:catalog_entries_preset_filter, preset_filters_options_for_select(Deployable::PRESET_FILTERS_OPTIONS, params[:catalog_entries_preset_filter]), :include_blank => t("catalog_entries.preset_filters.all_catalog_entries"), :disabled => true)
= restful_submit_tag t("filter_table.apply_filters"), "filter", filter_catalog_deployables_path(@catalog), 'POST', :class => 'button', :id => 'apply_catalog_entries_preset_filter'
- %span.label.badge.dark= @catalog_entries.count
+ %span.label.badge.dark= @deployables.count
%li.table-search-filter
= text_field_tag :catalog_entries_search, params[:catalog_entries_search], :placeholder => t("filter_table.search")
= restful_submit_tag "", "search", filter_catalog_deployables_path(@catalog), 'POST', :class => 'button', :id => 'apply_catalog_entries_search'
@@ -25,14 +25,14 @@
});
});
- = filter_table(@header, @catalog_entries) do |catalog_entry|
+ = filter_table(@header, @deployables) do |deployable|
%tr{:class => cycle('nostripe','stripe')}
%td{:class => 'checkbox'}
- selected = params[:select] == 'all'
- = check_box_tag "catalog_entries_selected[]", catalog_entry.id, selected, :id => "catalog_entry_checkbox_#{catalog_entry.id}"
+ = check_box_tag "deployables_selected[]", deployable.id, selected, :id => "deployable_checkbox_#{deployable.id}"
%td
- = link_to catalog_entry.deployable.name, catalog_deployable_path(@catalog, catalog_entry.id)
+ = link_to deployable.name, catalog_deployable_path(@catalog, deployable.id)
%td
- = link_to catalog_entry.catalog.name, catalog_entry.catalog
+ = link_to @catalog.name, @catalog
%td
- = link_to catalog_entry.deployable.xml_filename, catalog_deployable_path(@catalog, catalog_entry.id)
+ = link_to deployable.xml_filename, catalog_deployable_path(@catalog, deployable.id)
diff --git a/src/app/views/deployables/_new_from_image.html.haml b/src/app/views/deployables/_new_from_image.html.haml
index f546698..2e1b285 100644
--- a/src/app/views/deployables/_new_from_image.html.haml
+++ b/src/app/views/deployables/_new_from_image.html.haml
@@ -1,12 +1,12 @@
%header.admin-page-header
- %h1.deployables= t('.catalog_entry_name', :name => @catalog_entry.deployable.name)
+ %h1.deployables= t('.catalog_entry_name', :name => @deployable.name)
%section.admin-content-section
.content.buildpush
- = form_for @catalog_entry, :html => {:class => 'generic'} do |form|
+ = form_for @deployable, :html => {:class => 'generic'} do |form|
= hidden_field_tag :create_from_image, params[:create_from_image]
- - if @catalog_entry.errors.any?
- = render 'layouts/error_messages', :object => @catalog_entry
+ - if @deployable.errors.any?
+ = render 'layouts/error_messages', :object => @deployable
.lefted.new-catalog-entry-from-image
%h2= t('.title')
%p= t('.description', :name => @image.name)
@@ -17,8 +17,8 @@
.clear
%div
= form.label :catalog_id, t('catalog_entries.form.catalog')
- = form.select :catalog_id, @catalogs.collect{|c| [c.name, c.id]}
- %span.text_instead_input= "Catalog1"
+ /= form.select :catalog_id, @catalogs.collect{|c| [c.name, c.id]}
+ %span.text_instead_input= @selected_catalogs.empty? ? t('deployables.form.none') : @selected_catalogs.count > 1 ? t('deployables.form.multiple') : @selected_catalogs.first.name
%span.catalog_link
 
%div.catalog_list
@@ -26,7 +26,7 @@
- @catalogs.each do |catalog|
%li.catalog
.catalog_with_checkbox
- = check_box_tag :catalog_ids
+ = check_box_tag 'catalog_id[]', catalog.id, @selected_catalogs.any?{|c| c.id == catalog.id}
= catalog.name
.clear
.clear
diff --git a/src/app/views/deployables/_upload.html.haml b/src/app/views/deployables/_upload.html.haml
index 475d492..6afaa8f 100644
--- a/src/app/views/deployables/_upload.html.haml
+++ b/src/app/views/deployables/_upload.html.haml
@@ -1,22 +1,21 @@
-= form_for @catalog_entry, :url => catalog_deployables_path(@catalog), :html => {:class => 'generic', :multipart => true } do |form|
- - if @catalog_entry.errors.any?
- = render 'layouts/error_messages', :object => @catalog_entry
+= form_for @deployable, :url => catalog_deployables_path(@catalog), :html => {:class => 'generic', :multipart => true } do |form|
+ - if @deployable.errors.any?
+ = render 'layouts/error_messages', :object => @deployable
%fieldset
%p
- = form.label :catalog_id, t('catalog_entries.form.catalog')
+ = label_tag :catalog_id, t('catalog_entries.form.catalog')
%span.text_instead_input= @catalog.name
.clear
- = form.fields_for :deployable, @catalog_entry.deployable do |deployable_fields|
- %fieldset
- %p
- = deployable_fields.label :name, t('catalog_entries.index.name')
- = deployable_fields.text_field :name, :class => 'em long'
- %p
- = deployable_fields.label :description, t('catalog_entries.form.description')
- = deployable_fields.text_area :description, :class => 'long'
- %p
- = deployable_fields.label :xml, t('catalog_entries.form.choose_xml')
- = deployable_fields.file_field :xml
+ %fieldset
+ %p
+ = form.label :name, t('catalog_entries.index.name')
+ = form.text_field :name, :class => 'em long'
+ %p
+ = form.label :description, t('catalog_entries.form.description')
+ = form.text_area :description, :class => 'long'
+ %p
+ = form.label :xml, t('catalog_entries.form.choose_xml')
+ = form.file_field :xml
%fieldset
%p
= check_box_tag(:edit_xml, true, false)
diff --git a/src/app/views/deployables/edit.html.haml b/src/app/views/deployables/edit.html.haml
index e76b3e2..942f422 100644
--- a/src/app/views/deployables/edit.html.haml
+++ b/src/app/views/deployables/edit.html.haml
@@ -1,15 +1,15 @@
= render :partial => 'layouts/admin_nav'
%header.admin-page-header
- %h1{:class => controller.controller_name}= @catalog_entry.deployable.name
+ %h1{:class => controller.controller_name}= @deployable.name
#obj_actions.button-container
- = link_to 'New Deployable', new_catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry), :class => 'button primary', :id => 'new_deployable_button'
+ = link_to 'New Deployable', new_catalog_deployable_path(@catalog, @deployable), :class => 'button primary', :id => 'new_deployable_button'
.button-group
- = link_to 'Cancel Editing', catalog_deployables_path((a)catalog_entry.catalog), :class => 'button pill danger', :id => 'new_deployable_button'
+ = link_to 'Cancel Editing', catalog_deployables_path(@catalog), :class => 'button pill danger', :id => 'new_deployable_button'
%section.admin-content-section.user
%header
%h2=t'catalog_entries.edit.editing_catalog_entry'
.content
- = form_for @catalog_entry, :url => catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry), :html => { :method => :put, :class => 'generic' } do |f|
+ = form_for @deployable, :url => catalog_deployable_path(@catalog, @deployable), :html => { :method => :put, :class => 'generic' } do |f|
= render :partial => "form", :locals => { :form => f }
diff --git a/src/app/views/deployables/show.html.haml b/src/app/views/deployables/show.html.haml
index 1eab46e..e09f4bf 100644
--- a/src/app/views/deployables/show.html.haml
+++ b/src/app/views/deployables/show.html.haml
@@ -1,12 +1,12 @@
= render :partial => 'layouts/admin_nav'
%header.admin-page-header
- %h1{:class => controller.controller_name}= @catalog_entry.deployable.name
+ %h1{:class => controller.controller_name}= @deployable.name
#obj_actions.button-container
.button-group
- = button_to t('catalog_entries.show.delete'), catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry), :method => 'delete', :confirm => "#{t'catalog_entries.show.confirm_delete'}", :class => 'button danger', :id => 'delete'
- = link_to t('catalog_entries.show.edit'), edit_catalog_deployable_path((a)catalog_entry.catalog, @catalog_entry), :class => 'button', :id => 'edit_button'
+ = button_to t('catalog_entries.show.delete'), catalog_deployable_path(@catalog, @deployable), :method => 'delete', :confirm => "#{t'catalog_entries.show.confirm_delete'}", :class => 'button danger', :id => 'delete'
+ = link_to t('catalog_entries.show.edit'), edit_catalog_deployable_path(@catalog, @deployable), :class => 'button', :id => 'edit_button'
- = link_to t('deployments.overview.launch'), launch_new_deployments_path(:deployable_id => @catalog_entry.deployable.id, :pool_id => @catalog_entry.catalog.pool), :id => :launch_deployment
+ = link_to t('deployments.overview.launch'), launch_new_deployments_path(:deployable_id => @deployable.id, :pool_id => @catalog.pool), :id => :launch_deployment
%section.admin-content-section.deployable
%section.image
@@ -61,7 +61,7 @@
%p= t('.choose_catalog')
= form_for(:catalog_entry, :url => catalog_entries_path) do |f|
= f.select :catalog_id, options_for_select(@catalogs_options)
- = f.hidden_field(:deployable_id, :value => @catalog_entry.deployable.id)
+ = f.hidden_field(:deployable_id, :value => @deployable.id)
= f.submit t('catalog_entries.show.add_catalog'), :id => :add_catalog
%table
@@ -70,10 +70,10 @@
%label= t('.catalog_name')
%th
%label= t('.environment')
- - @catalog_entry.deployable.catalog_entries.each do |catalog_entry|
+ - @deployable.catalog_entries.each do |catalog_entry|
%tr
%td
- = button_to t('catalog_entries.show.delete'), catalog_entry_path(@catalog_entry), :method => 'delete', :confirm => "#{t'catalog_entries.show.confirm_delete'}", :id => 'delete'
+ = button_to t('catalog_entries.show.delete'), catalog_entry_path(catalog_entry), :method => 'delete', :confirm => "#{t'catalog_entries.show.confirm_delete'}", :id => 'delete'
= catalog_entry.catalog.name
%td= catalog_entry.catalog.pool.pool_family.name
diff --git a/src/config/locales/en.yml b/src/config/locales/en.yml
index 64512ec..e45d743 100644
--- a/src/config/locales/en.yml
+++ b/src/config/locales/en.yml
@@ -786,6 +786,9 @@ en:
flash:
error:
attribute_not_exist: "Some attribute(s) is missing in XML, please check the file!"
+ no_catalog: "No catalogs selected"
+ warning:
+ failed: "Deployable was not created: %{message}"
error:
attribute_not_exists: invalid
hwp_not_exists: "Hardware profile %{name} doesn't exist in DB"
diff --git a/src/features/deployables.feature b/src/features/deployables.feature
index d950c50..f551a14 100644
--- a/src/features/deployables.feature
+++ b/src/features/deployables.feature
@@ -13,27 +13,27 @@ Feature: Manage Catalog Entries
Then I should see "Catalog Entries"
When I follow "new_catalog_entry_button"
Then I should see "Add New Catalog Entry"
- When I fill in "catalog_entry[deployable_attributes][name]" with "test1"
- And I fill in "catalog_entry[deployable_attributes][description]" with "description"
- When I attach the file "features/upload_files/deployable.xml" to "catalog_entry[deployable_attributes][xml]"
+ When I fill in "deployable[name]" with "test1"
+ And I fill in "deployable[description]" with "description"
+ When I attach the file "features/upload_files/deployable.xml" to "deployable[xml]"
And I press "save_button"
Then I should see "Catalog entry added"
Scenario: Change the name
Given there is a "default" catalog
- And a catalog entry "testdepl" exists
+ And a catalog entry "testdepl" exists for "default" catalog
When I am on the "default" catalog catalog entries page
When I follow "testdepl"
And I follow "edit_button"
Then I should see "Editing Catalog Entry"
- When I fill in "catalog_entry[deployable_attributes][name]" with "testdepl-renamed"
+ When I fill in "deployable[name]" with "testdepl-renamed"
And I press "save_button"
Then I should see "Catalog entry updated successfully!"
And I should see "testdepl-renamed"
Scenario: Show catalog entry details
Given there is a "default" catalog
- And a catalog entry "testdepl" exists
+ And a catalog entry "testdepl" exists for "default" catalog
And I am on the "default" catalog catalog entries page
When I follow "testdepl"
Then I should see "testdepl"
@@ -44,7 +44,7 @@ Feature: Manage Catalog Entries
Scenario: Launch a deployment
Given there is a "default" catalog
- And a catalog entry "testdepl" exists
+ And a catalog entry "testdepl" exists for "default" catalog
And I am on testdepl's catalog entry page
When I follow "launch_deployment"
Then I should be on the launch new deployments page
@@ -57,7 +57,7 @@ Feature: Manage Catalog Entries
When I check "testdepl1" catalog entry
And I check "testdepl2" catalog entry
And I press "delete_button"
- Then there should be only 0 catalog entries
+ Then there should be only 0 catalog entries for "default" catalog
And I should be on the "default" catalog page
And I should not see "testdepl1"
And I should not see "testdepl2"
@@ -68,7 +68,7 @@ Feature: Manage Catalog Entries
And I am on the "default" catalog page
When I follow "testdepl1"
And I press "delete"
- Then there should be only 0 catalog entries
+ Then there should be only 0 catalog entries for "default" catalog
And I should be on the "default" catalog page
And I should not see "testdepl1"
diff --git a/src/features/step_definitions/deployable_steps.rb b/src/features/step_definitions/deployable_steps.rb
index 73bf7be..62e45ee 100644
--- a/src/features/step_definitions/deployable_steps.rb
+++ b/src/features/step_definitions/deployable_steps.rb
@@ -1,15 +1,11 @@
-Given /^a catalog entry "([^"]*)" exists$/ do |arg1|
- deployable = FactoryGirl.create :deployable, :name => arg1
- entry = FactoryGirl.create :catalog_entry, :deployable => deployable
-end
-
When /^I check "([^"]*)" catalog entry$/ do |arg1|
dep = CatalogEntry.find_by_deployable_id(Deployable.find_by_name(arg1))
- check("catalog_entry_checkbox_#{dep.id}")
+ check("deployable_checkbox_#{dep.id}")
end
-Then /^there should be only (\d+) catalog entries$/ do |arg1|
- CatalogEntry.count.should == arg1.to_i
+Then /^there should be only (\d+) catalog entries for "([^"]*)" catalog$/ do |arg1, catalog_name|
+ catalog = Catalog.find_by_name(catalog_name) || FactoryGirl.create(:catalog, :name => catalog_name)
+ catalog.catalog_entries.count.should == arg1.to_i
end
Given /^a catalog entry "([^"]*)" exists for "([^"]*)" catalog$/ do |arg1, catalog_name|
diff --git a/src/spec/controllers/deployables_controller_spec.rb b/src/spec/controllers/deployables_controller_spec.rb
index eb0a6f8..09d1917 100644
--- a/src/spec/controllers/deployables_controller_spec.rb
+++ b/src/spec/controllers/deployables_controller_spec.rb
@@ -39,7 +39,7 @@ describe DeployablesController do
hw_profile = FactoryGirl.create(:front_hwp1)
catalog = FactoryGirl.create(:catalog)
mock_warden(@admin)
- post(:create, :create_from_image => @image.id, :hardware_profile => hw_profile.id, :catalog_entry => {:catalog_id => catalog.id})
+ post(:create, :create_from_image => @image.id, :hardware_profile => hw_profile.id, :catalog_id => catalog.id)
response.should redirect_to(catalog_deployables_url(catalog.id))
end
--
1.7.6
12 years, 4 months
Migration fixes
by Jason Guiditta
The following 2 migrations failed for me on sqlite, so I fixed them.
These patches have been tested on postgres and sqlite, but not mysql. If
they work there too, great, but making one more db work for now seems
worthwhile to me. If you have mysql setup and would like to give this a
go, great, but I woudl like to push this asap to at least get sqlite
functional again.
-j
[PATCH conductor 1/2] Fix this migration so it also works on sqlite.
[PATCH conductor 2/2] Change sql statement to use rails helpers.
12 years, 4 months
iwhd-1.1 released [stable]
by Jim Meyering
Here's the latest version of iwhd.
iwhd is Aeolus' (http://aeolusproject.org/)
rule-based cloud-to-cloud image manager.
Since 1.0 there have been significant logging improvements
that should make it easy for anyone trying to deduce what iwhd
is doing via its logs. This release also includes fixes for
an erroneous URL and a syntax error, both in JSON GET results.
See the NEWS below.
Here are the compressed sources:
http://people.redhat.com/meyering/iwhd/iwhd-1.1.tar.gz (1.4MB)
http://people.redhat.com/meyering/iwhd/iwhd-1.1.tar.xz (832KB)
Here are the GPG detached signatures[*]:
http://people.redhat.com/meyering/iwhd/iwhd-1.1.tar.gz.sig
http://people.redhat.com/meyering/iwhd/iwhd-1.1.tar.xz.sig
[*] You can use either of the above signature files to verify that
the corresponding file (without the .sig suffix) is intact. First,
be sure to download both the .sig file and the corresponding tarball.
Then, run a command like this:
gpg --verify iwhd-1.1.tar.gz.sig
If that command fails because you don't have the required public key,
then run this command to import it:
gpg --keyserver keys.gnupg.net --recv-keys 000BEEEE
and rerun the `gpg --verify' command.
This release was bootstrapped with the following tools:
Autoconf 2.68.95-e0cb9
Automake 1.11a
Gnulib v0.0-6363-g996ce97
======================================================================
NEWS
* Noteworthy changes in release 1.1 (2011-12-01) [stable]
** Bug fixes
The response to a query like the following
curl -H 'Accept: */json' http://H:9090/b/o/_attrs
now includes an "object_body" URL of "http://H:9090/b/o/", which
matches the XML-formatted one, rather than "http://H:9090/b/o/body".
That same line now ends with a comma, too.
[bug introduced in 0.91]
** Changes in behavior
iwhd now rejects a --userlist file that is group- or other-readable
or -writable.
The request logging is reorganized. Now, 2 messages are logged for
every request. They report the method, path, requested and actual size,
and the HTTP result code.
12 years, 4 months
[PATCH] Added ASL license header to files
by Francesco Vollero
Signed-off-by: Francesco Vollero <fvollero(a)redhat.com>
---
lib/aeolus_image/model/factory/base.rb | 15 +++++++++++++++
lib/aeolus_image/model/factory/build.rb | 15 +++++++++++++++
lib/aeolus_image/model/factory/builder.rb | 15 +++++++++++++++
lib/aeolus_image/model/factory/image.rb | 15 +++++++++++++++
lib/aeolus_image/model/factory/provider_image.rb | 15 +++++++++++++++
lib/aeolus_image/model/factory/target_image.rb | 15 +++++++++++++++
spec/models/factory/base.rb | 15 +++++++++++++++
spec/vcr_setup.rb | 15 +++++++++++++++
8 files changed, 120 insertions(+), 0 deletions(-)
diff --git a/lib/aeolus_image/model/factory/base.rb b/lib/aeolus_image/model/factory/base.rb
index 7947da1..d4f8a94 100644
--- a/lib/aeolus_image/model/factory/base.rb
+++ b/lib/aeolus_image/model/factory/base.rb
@@ -1,3 +1,18 @@
+#
+# Copyright 2011 Red Hat, 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 Aeolus
module Image
module Factory
diff --git a/lib/aeolus_image/model/factory/build.rb b/lib/aeolus_image/model/factory/build.rb
index b238cea..c479a68 100644
--- a/lib/aeolus_image/model/factory/build.rb
+++ b/lib/aeolus_image/model/factory/build.rb
@@ -1,3 +1,18 @@
+#
+# Copyright 2011 Red Hat, 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 Aeolus
module Image
module Factory
diff --git a/lib/aeolus_image/model/factory/builder.rb b/lib/aeolus_image/model/factory/builder.rb
index 196d870..99e7b8f 100644
--- a/lib/aeolus_image/model/factory/builder.rb
+++ b/lib/aeolus_image/model/factory/builder.rb
@@ -1,3 +1,18 @@
+#
+# Copyright 2011 Red Hat, 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 Aeolus
module Image
module Factory
diff --git a/lib/aeolus_image/model/factory/image.rb b/lib/aeolus_image/model/factory/image.rb
index 712457f..a961eaa 100644
--- a/lib/aeolus_image/model/factory/image.rb
+++ b/lib/aeolus_image/model/factory/image.rb
@@ -1,3 +1,18 @@
+#
+# Copyright 2011 Red Hat, 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 Aeolus
module Image
module Factory
diff --git a/lib/aeolus_image/model/factory/provider_image.rb b/lib/aeolus_image/model/factory/provider_image.rb
index dec34d9..f3756f4 100644
--- a/lib/aeolus_image/model/factory/provider_image.rb
+++ b/lib/aeolus_image/model/factory/provider_image.rb
@@ -1,3 +1,18 @@
+#
+# Copyright 2011 Red Hat, 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 Aeolus
module Image
module Factory
diff --git a/lib/aeolus_image/model/factory/target_image.rb b/lib/aeolus_image/model/factory/target_image.rb
index 7410b5b..3eb6ba5 100644
--- a/lib/aeolus_image/model/factory/target_image.rb
+++ b/lib/aeolus_image/model/factory/target_image.rb
@@ -1,3 +1,18 @@
+#
+# Copyright 2011 Red Hat, 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 Aeolus
module Image
module Factory
diff --git a/spec/models/factory/base.rb b/spec/models/factory/base.rb
index da5d0aa..86b8a70 100644
--- a/spec/models/factory/base.rb
+++ b/spec/models/factory/base.rb
@@ -1,3 +1,18 @@
+#
+# Copyright 2011 Red Hat, 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.
+#
require 'spec_helper'
require 'timecop'
diff --git a/spec/vcr_setup.rb b/spec/vcr_setup.rb
index 1d79608..0216c9b 100644
--- a/spec/vcr_setup.rb
+++ b/spec/vcr_setup.rb
@@ -1,3 +1,18 @@
+#
+# Copyright 2011 Red Hat, 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.
+#
require 'vcr'
require 'oauth'
require File.join(File.dirname(__FILE__), '../lib', 'aeolus_image')
--
1.7.4.4
12 years, 4 months
[PATCH] Changed the license from GPL to ASL
by Francesco Vollero
Signed-off-by: Francesco Vollero <fvollero(a)redhat.com>
---
spec/vcr_setup.rb | 24 +++++++++++-------------
1 files changed, 11 insertions(+), 13 deletions(-)
diff --git a/spec/vcr_setup.rb b/spec/vcr_setup.rb
index 3913611..e170a3a 100644
--- a/spec/vcr_setup.rb
+++ b/spec/vcr_setup.rb
@@ -1,20 +1,18 @@
#
-# Copyright (C) 2011 Red Hat, Inc.
+# Copyright 2011 Red Hat, Inc.
#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
+# 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
#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
+# 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.
#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
-# MA 02110-1301, USA. A copy of the GNU General Public License is
-# also available at http://www.gnu.org/copyleft/gpl.html.
require 'vcr'
--
1.7.4.4
12 years, 4 months