Revision 3ace60a5
Added by Ohad Levy almost 12 years ago
- ID 3ace60a5690ded35e264cc8188d11ae4b8ba5dd7
db/migrate/20120623002052_add_ok_hosts_book_mark.rb | ||
---|---|---|
|
||
def self.up
|
||
Bookmark.find_or_create_by_name_and_query_and_controller :name => "ok hosts", :query => 'last_report > "35 minutes ago" and status.enabled = true and status.applied = 0 and status.failed = 0 and status.pending = 0', :controller=> "hosts", :public => true
|
||
rescue
|
||
# don't fail because we can't create a bookmark
|
||
true
|
||
end
|
||
|
||
def self.down
|
Also available in: Unified diff
minimal fix for unexplained db migrations failures, refs #1736