Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 91 lines (80 sloc) 3.344 kB
d515ce0 @jreidinger add license header to almost all webservice-base files
jreidinger authored
1 #--
2 # Copyright (c) 2009, 2010 Novell, Inc.
3 #
4 # All Rights Reserved.
5 #
6 # This program is free software; you can redistribute it and/or modify it
7 # under the terms of version 2 of the GNU General Public License
8 # as published by the Free Software Foundation.
9 #
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
14 #
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, contact Novell, Inc.
17 #
18 # To contact Novell about this file by physical or electronic mail,
19 # you may find current contact information at www.novell.com
20 #++
21 #
f4f6791 Initial framework
Michael Andres authored
22 # Add your own tasks in files placed in lib/tasks ending in .rake,
23 # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
24
25 require(File.join(File.dirname(__FILE__), 'config', 'boot'))
653f5c0 @schubi2 merged conti.
schubi2 authored
26 $:.unshift File.join(File.dirname(__FILE__), "..", "webyast-tasks", "lib")
f4f6791 Initial framework
Michael Andres authored
27
28 require 'rake'
29 require 'rake/testtask'
30 require 'rake/rdoctask'
31
e2623c4 @jreidinger add doc:app rake task to include plugin test helper documentation, ca…
jreidinger authored
32 #include in doc:app also shared test enhancements for plugins
33 #FIXME find way how to change original rails task app:doc we only need include some files to it
34 namespace :doc do
35 Rake::RDocTask.new("app") { |rdoc|
36 rdoc.rdoc_dir = 'doc/app'
37 rdoc.title = "Rails Application Documentation"
38 rdoc.options << '--line-numbers' << '--inline-source'
39 rdoc.rdoc_files.include('doc/README_FOR_APP')
40 rdoc.rdoc_files.include('app/**/*.rb')
41 rdoc.rdoc_files.include('lib/**/*.rb')
42 #include shared test functionality in documentation
43 rdoc.rdoc_files.include('test/plugin_basic_tests.rb')
44 }
45 end
fccab63 added deploy_devel_all task, which deploys restservice from git tree.
Martin Kudlvasr authored
46
47 # load the shared rake files from the package itself
48 # skip 'deploy_local' task, it's redefined here
653f5c0 @schubi2 merged conti.
schubi2 authored
49 require 'tasks/webyast_tasks'
50 WebyastTasks.loadTasks(:exclude => ["deploy_local.rake"])
fccab63 added deploy_devel_all task, which deploys restservice from git tree.
Martin Kudlvasr authored
51
653f5c0 @schubi2 merged conti.
schubi2 authored
52 # this call also loads WebyastTasks but the second call is ignored there
53 # so this 'require' must be called _after_ WebyastTasks.loadTasks
8b7f184 @lslezak Fixed task loading
lslezak authored
54 require 'tasks/rails'
55
fccab63 added deploy_devel_all task, which deploys restservice from git tree.
Martin Kudlvasr authored
56 require 'fileutils'
57
0b81f4b @schubi2 cleanup
schubi2 authored
58 desc "Deploy for development - create basic dirs and install grantwebyastrights."
59 task :deploy_local do
fccab63 added deploy_devel_all task, which deploys restservice from git tree.
Martin Kudlvasr authored
60 FileUtils.mkdir_p "/etc/webyast"
926bc6f @schubi2 moved yastws to webyast
schubi2 authored
61 FileUtils.mkdir_p "/var/lib/webyast"
62 FileUtils.mkdir_p "/usr/share/webyast"
cbc6a53 @schubi2 starting zypper on demand
schubi2 authored
63 FileUtils.mkdir_p "/srv/www/webyast/log"
fccab63 added deploy_devel_all task, which deploys restservice from git tree.
Martin Kudlvasr authored
64 FileUtils.install "package/grantwebyastrights", "/usr/sbin", :mode => 0555
9088908 @jreidinger add to reke deploy of permissions service
jreidinger authored
65 mkdir_p "/etc/dbus-1/system.d/"
66 cp_r "package/webyast.permissions.conf", "/etc/dbus-1/system.d/"
87f0de4 @jreidinger fix packaging issues and also move to standart location
jreidinger authored
67 cp_r "package/webyastPermissionsService.rb", "/usr/sbin/"
c01e27d @jreidinger fix deploy of role server
jreidinger authored
68 chmod 0744, "/usr/sbin/webyastPermissionsService.rb"
9088908 @jreidinger add to reke deploy of permissions service
jreidinger authored
69 mkdir_p "/usr/share/dbus-1/system-services/"
32f98e6 @jreidinger fix dbus issue
jreidinger authored
70 cp_r "package/webyast.permissions.service.service", "/usr/share/dbus-1/system-services/"
435f556 @schubi2 using new polkit
schubi2 authored
71 `rake install_policies`
fccab63 added deploy_devel_all task, which deploys restservice from git tree.
Martin Kudlvasr authored
72 end
73
d28ad99 - added Delayed Jobs as plugin (TODO: use gem instead, unfortunately …
Vladislav Gorobets authored
74 #set constant to disable initializer for Delayed Job
75 task :environment => :disable_initializer
76
77 task :disable_initializer do
78 ENV["DISABLE_INITIALIZER"] = 'true'
79 end
1df3b2e @schubi2 mergining
schubi2 authored
80
81 namespace :sass do
82 desc 'Updates stylesheets if necessary from their Sass templates.'
83 task :update do
84 require 'sass/plugin'
85 Sass::Plugin.options = { :template_location => "app/sass" }
86 Sass::Plugin.update_stylesheets
87 #run css minifier task after sass to css converter
88 Rake::Task['css:min'].invoke
89 end
90 end
Something went wrong with that request. Please try again.