(no subject)
by Scott Seago
From: Scott Seago <sseago(a)redhat.com>
Subject: [PATCH conductor 0/8] revised patchset
In-Reply-To:
12 years, 8 months
[PATCH 0/2] Error Messages deprecations
by Jirka Tomasek
First patch fixes error_messages and error_message_on deprecation
warnings, second fixes Quota numericality validation in
RegistrationService
12 years, 8 months
[PATCH] Fix before_destroy deprecation warning
by Jirka Tomasek
---
src/app/models/instance_key.rb | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/src/app/models/instance_key.rb b/src/app/models/instance_key.rb
index c75f8af..49688f6 100644
--- a/src/app/models/instance_key.rb
+++ b/src/app/models/instance_key.rb
@@ -36,8 +36,9 @@
class InstanceKey < ActiveRecord::Base
belongs_to :instance
+ before_destroy :destroy_instance_key
- def before_destroy
+ def destroy_instance_key
begin
instance.provider_account.connect.key(self.name).destroy!
rescue
--
1.7.6
12 years, 8 months
[PATCH conductor] Show deleted instances in the CSV report
by Tomas Sedovic
From: Tomas Sedovic <tsedovic(a)redhat.com>
https://www.aeolusproject.org/redmine/issues/2141
---
src/app/controllers/instances_controller.rb | 17 +++++++++++------
src/app/models/instance.rb | 5 ++++-
2 files changed, 15 insertions(+), 7 deletions(-)
diff --git a/src/app/controllers/instances_controller.rb b/src/app/controllers/instances_controller.rb
index 09046a1..9a45d8a 100644
--- a/src/app/controllers/instances_controller.rb
+++ b/src/app/controllers/instances_controller.rb
@@ -150,7 +150,7 @@ class InstancesController < ApplicationController
end
def export_events
- send_data(Instance.csv_export(load_instances),
+ send_data(Instance.csv_export(load_instances :include_deleted => true),
:type => 'text/csv; charset=utf-8; header=present',
:filename => "export.csv")
end
@@ -186,12 +186,17 @@ class InstancesController < ApplicationController
@pools = Pool.list_for_user(@current_user, Privilege::CREATE, :target_type => Instance)
end
- def load_instances
+ def load_instances(opts)
+ opts ||= {}
conditions = { :pool_id => @pools }
conditions[:deployment_id] = params[:deployment_id] unless params[:deployment_id].blank?
- @instances = Instance.all(:include => [:owner],
- :conditions => conditions,
- :order => (params[:order_field] || 'name') +' '+ (params[:order_dir] || 'asc')
- )
+ order = (params[:order_field] || 'name') +' '+ (params[:order_dir] || 'asc')
+ query = { :include => [:owner],
+ :conditions => conditions,
+ :order => order }
+ @instances = Instance.all(query)
+
+ @instances.concat(Instance::Archive.all) if opts[:include_deleted]
+ return @instances
end
end
diff --git a/src/app/models/instance.rb b/src/app/models/instance.rb
index e1e2d39..042e3ab 100644
--- a/src/app/models/instance.rb
+++ b/src/app/models/instance.rb
@@ -348,7 +348,10 @@ class Instance < ActiveRecord::Base
csv << event_attributes.map {|event| event.capitalize }
- events = instances.map{|i| i.events}.flatten!
+ events = instances.map do |i|
+ Event.find_all_by_source_id_and_source_type(i.id, 'Instance')
+ end
+ events.flatten!
unless events.nil?
events.each do |event|
csv << event_attributes.map {|event_attribute| event[event_attribute] }
--
1.7.6
12 years, 8 months
Sprint scenarios (part 2)
by Jan Provazník
Sending scenarios which remained for tomorrow call:
- As a user, I would like to see clean deletion confirmation pages for
any top-level object that has the potential to directly affect instances
or people, or permissions.
- As a user I want a UI to enable browsing of images in the warehouse to
which the user has permission, and which can be launched in the current
pool.
- As a user I should be able to share identity in Conductor and katello
- As a user, I need UX design for inputting of launch time parameters.
- As a developer, I need UX design for the management of roles &
permissions.
Jan
12 years, 8 months
Some rspec tests
by Tomas Hrcka
This patch set contains rewrite of previously commented JSON cucumber tests to rspec
12 years, 8 months
[PATCH conductor] Rack-restful_submit hotfix
by Jan Provazník
From: Jan Provaznik <jprovazn(a)redhat.com>
restful_submit plugin doesn't work properly in rails 3 if rails
relative root url (/conductor) is used. This is a temporary fix
until fix get into rack-restful_submit release.
This patch removes root prefix from restful_submit paths (as rails 3
apparently expects paths w/o root prefix).
---
src/config/initializers/rack-restful_submit.rb | 19 +++++++++++++++++++
1 files changed, 19 insertions(+), 0 deletions(-)
create mode 100644 src/config/initializers/rack-restful_submit.rb
diff --git a/src/config/initializers/rack-restful_submit.rb b/src/config/initializers/rack-restful_submit.rb
new file mode 100644
index 0000000..3123a27
--- /dev/null
+++ b/src/config/initializers/rack-restful_submit.rb
@@ -0,0 +1,19 @@
+module Rack
+ class RestfulSubmit
+ def rewrite_request(env, prefixed_uri)
+ # rails 3 expects that relative_url_root is not part of
+ # requested uri, this fix also expects that mapping['url']
+ # contains only path (not full url)
+ uri = prefixed_uri.sub(/^#{Regexp.escape(env['SCRIPT_NAME'].to_s)}\//, '/')
+
+ env['REQUEST_URI'] = uri
+ if q_index = uri.index('?')
+ env['PATH_INFO'] = uri[0..q_index-1]
+ env['QUERYSTRING'] = uri[q_index+1..uri.size-1]
+ else
+ env['PATH_INFO'] = uri
+ env['QUERYSTRING'] = ''
+ end
+ end
+ end
+end
--
1.7.6
12 years, 8 months
RFC: End-of-Sprint Minor Release Approaching
by steve linabery
Since our release process has become easier of late, I would like to try to do a minor release (0.3.1) of the aeolus packages at the end of the current sprint (Tuesday, 23 August).
For that to work, it would be ideal to have all patches tested and pushed by Friday, 19 August. That's the RFC part of this message: do we think it would be possible to make that deadline?
Ideally, in order to do releases at the end of each sprint, we should have a few days built in for packaging and testing. How do you see our chances for doing that this sprint?
TIA for your input,
Steve|eggs
12 years, 8 months