RedmineRake » History » Version 12

Etienne Massip, 2013-06-06 22:26

1 3 Etienne Massip
h1. Rake tasks
2 1 Etienne Massip
3 1 Etienne Massip
p{color:red}. WIP
4 1 Etienne Massip
5 1 Etienne Massip
{{>toc}}
6 1 Etienne Massip
7 1 Etienne Massip
Redmine defines a set of "Rake":http://rake.rubyforge.org tasks for use in maintenance operations.
8 1 Etienne Massip
9 7 Etienne Massip
Information about tasks defined by the Ruby on Rails framework are accessible on "the dedicated page":http://guides.rubyonrails.org/command_line.html#rake.
10 1 Etienne Massip
11 12 Etienne Massip
At any time you can get the full list of tasks using command @rake -T@.
12 12 Etienne Massip
13 12 Etienne Massip
*When running a task* don't forget to set @RAILS_ENV@ variable to ??production??!
14 12 Etienne Massip
15 12 Etienne Massip
E.g. (*nix style):
16 12 Etienne Massip
17 12 Etienne Massip
 rake redmine:permissions RAILS_ENV=production
18 12 Etienne Massip
19 12 Etienne Massip
or (Windows style):
20 12 Etienne Massip
21 12 Etienne Massip
 set RAILS_ENV=production
22 12 Etienne Massip
rake redmine:permissions
23 12 Etienne Massip
24 7 Etienne Massip
h2. Batch job tasks
25 7 Etienne Massip
26 7 Etienne Massip
h3. @rake redmine:attachments:prune@
27 7 Etienne Massip
28 9 Etienne Massip
_Applicable starting from version version:2.3.0._
29 1 Etienne Massip
30 5 Trevor Jones
When a user attaches a file to an issue, a wiki page, etc., the file is immediately uploaded and is attached later on after the form has been submitted.
31 5 Trevor Jones
32 1 Etienne Massip
This task removes uploaded files left unattached (meaning the form has never been submitted) after one day.
33 5 Trevor Jones
34 7 Etienne Massip
h3. @rake redmine:email:read@
35 5 Trevor Jones
36 5 Trevor Jones
Read an email from standard input.
37 5 Trevor Jones
38 7 Etienne Massip
h3. @rake redmine:email:receive_imap@
39 5 Trevor Jones
40 5 Trevor Jones
Read emails from an IMAP server.
41 5 Trevor Jones
42 7 Etienne Massip
h3. @rake redmine:email:receive_pop3@
43 5 Trevor Jones
44 5 Trevor Jones
Read emails from an POP3 server.
45 5 Trevor Jones
46 7 Etienne Massip
h3. @rake redmine:fetch_changesets@
47 5 Trevor Jones
48 5 Trevor Jones
Fetch changesets from the repositories
49 5 Trevor Jones
50 7 Etienne Massip
h3. @rake redmine:send_reminders@
51 5 Trevor Jones
52 5 Trevor Jones
Send reminders about issues due in the next days.
53 5 Trevor Jones
See: [[RedmineReminderEmails]]
54 5 Trevor Jones
55 7 Etienne Massip
h3. @rake redmine:tokens:prune@
56 5 Trevor Jones
57 5 Trevor Jones
Removes expired tokens.
58 5 Trevor Jones
59 7 Etienne Massip
h3. @rake redmine:watchers:prune@
60 5 Trevor Jones
61 1 Etienne Massip
Removes watchers from what they can no longer view.
62 5 Trevor Jones
Available in versions version:2.3.0
63 5 Trevor Jones
64 7 Etienne Massip
h2. Other maintenance tasks
65 5 Trevor Jones
66 8 Etienne Massip
h3. @rake generate_secret_token@
67 5 Trevor Jones
68 7 Etienne Massip
Generates a secret token for the application.
69 5 Trevor Jones
70 7 Etienne Massip
h3. @rake db:encrypt@ and @rake db:decrypt@
71 5 Trevor Jones
72 7 Etienne Massip
Encrypts or decrypts SCM and LDAP passwords stored in the database.
73 5 Trevor Jones
74 7 Etienne Massip
h3. @rake redmine:attachments:move_to_subdirectories@
75 5 Trevor Jones
76 7 Etienne Massip
Moves attachments stored at the root of the file directory (ie.
77 5 Trevor Jones
Available in versions version:2.3.0
78 5 Trevor Jones
79 7 Etienne Massip
h3. @rake redmine:email:test[login]@
80 5 Trevor Jones
81 7 Etienne Massip
Send a test email to the user with the provided login name
82 5 Trevor Jones
83 7 Etienne Massip
h3. @rake redmine:permissions@
84 5 Trevor Jones
85 7 Etienne Massip
List all permissions and the actions registered with them
86 5 Trevor Jones
87 7 Etienne Massip
h3. @rake redmine:plugins@
88 5 Trevor Jones
89 7 Etienne Massip
Migrates and copies plugins assets.
90 5 Trevor Jones
91 7 Etienne Massip
h3. @rake redmine:plugins:assets@
92 5 Trevor Jones
93 7 Etienne Massip
Copies plugins assets into the public directory.
94 5 Trevor Jones
95 7 Etienne Massip
h3. @rake redmine:plugins:migrate@
96 5 Trevor Jones
97 7 Etienne Massip
Migrates installed plugins.
98 5 Trevor Jones
99 7 Etienne Massip
h2. Migrating from another BTS
100 5 Trevor Jones
101 7 Etienne Massip
h3. @rake redmine:migrate_from_mantis@
102 5 Trevor Jones
103 7 Etienne Massip
Mantis migration script
104 5 Trevor Jones
105 7 Etienne Massip
h3. @rake redmine:migrate_from_trac@
106 5 Trevor Jones
107 7 Etienne Massip
Trac migration script