/usr/share/obs/api/Rakefile is in obs-api 2.7.4-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | # Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
# Work around for jquery-datatables-rails-1.12.2
$LOAD_PATH.unshift '/usr/share/obs/api/vendor/gems/jquery-datatables-rails-1.12.2/lib'
require File.expand_path('../config/application', __FILE__)
OBSApi::Application.load_tasks
require(File.join(File.dirname(__FILE__), 'config', 'boot'))
require 'workers/update_issues.rb'
task(:updateissues => :environment) { Delayed::Job.enqueue UpdateIssuesJob.new }
task(:updatepackagemeta => :environment) { UpdatePackageMetaJob.new.perform }
# write directly to backend, for initial bootup in obsapisetup
task(:writeconfiguration => :environment) { ::Configuration.first.write_to_backend }
require 'workers/import_requests.rb'
task(:importrequests => :environment) { ImportRequestsDelayedJob.new.perform }
require File.expand_path('app/jobs/consistency_check.rb')
task(:check_project => :environment) { ConsistencyCheckJob.new.check_project }
task(:fix_project => :environment) { ConsistencyCheckJob.new.fix_project }
unless Rails.env.production?
require 'rubocop/rake_task'
RuboCop::RakeTask.new(:rubocop) do |task|
task.options = [ '-D', '-F', '--fail-level', 'convention' ]
end
end
if Rails.env.test?
require 'single_test/tasks'
begin
require 'ci/reporter/rake/minitest'
rescue LoadError
puts "Please run 'rake gems:install' to install the 'ci_reporter' gem."
end
end
|