Benjamin Renard commited on 2014-12-31 09:50:58
Showing 1 changed files, with 88 additions and 0 deletions.
| ... | ... |
@@ -0,0 +1,88 @@ |
| 1 |
+Check Update script for Roundcube Webmail |
|
| 2 |
+========================================= |
|
| 3 |
+ |
|
| 4 |
+This script permit to check if an Roundcube Webmail is up to date. |
|
| 5 |
+ |
|
| 6 |
+It retreive current stable version on Roundcube Webmail Website and |
|
| 7 |
+compare it to the local version. If the local version is different |
|
| 8 |
+than the current stable version, it notify you by email. |
|
| 9 |
+ |
|
| 10 |
+The original script it design to be run by cron, but you could now |
|
| 11 |
+use the script as Nagios check plugin (-n parameter). |
|
| 12 |
+ |
|
| 13 |
+Upgrading your Roundcube Webmail installation |
|
| 14 |
+--------------------------------------------- |
|
| 15 |
+ |
|
| 16 |
+The script could also help you to upgrade your installation. By |
|
| 17 |
+running the script with the -u parameter, it will automatically : |
|
| 18 |
+ - download and uncompress for you the newest version from Roundcube |
|
| 19 |
+ Webmail Website in an upstream directory |
|
| 20 |
+ - duplicate current installation data in a new directory |
|
| 21 |
+ - upgrade this duplicated installation by using 'installto.sh' script |
|
| 22 |
+ provide by Roundcube Webmail project |
|
| 23 |
+ - Optional : execute a custom bash function after_upgrade() if defined. |
|
| 24 |
+ It could be useful if you have custom modification in your installation. |
|
| 25 |
+ - If the current installation path is a symlink, it propose you to change |
|
| 26 |
+ the destionation of this symlink to the new installation path. |
|
| 27 |
+ |
|
| 28 |
+Usage |
|
| 29 |
+----- |
|
| 30 |
+ |
|
| 31 |
+ Usage : ./check_rc_upgrade.sh [-v] [-n] [-d] [-u] |
|
| 32 |
+ -v Verbose mode |
|
| 33 |
+ -n Nagios mode |
|
| 34 |
+ -d Download new release |
|
| 35 |
+ -u Upgrade installation |
|
| 36 |
+ -j Just display current stable version |
|
| 37 |
+ -h Display this help |
|
| 38 |
+ |
|
| 39 |
+Configuration |
|
| 40 |
+------------- |
|
| 41 |
+ |
|
| 42 |
+The configuration of this script is located on top of it. It recommand |
|
| 43 |
+to copy the variables in a second file check_rc_upgrade.sh.local. This |
|
| 44 |
+file will be included if present. |
|
| 45 |
+ |
|
| 46 |
+Parameters : |
|
| 47 |
+ |
|
| 48 |
+ - RC_HOME : |
|
| 49 |
+ The full path of your Roundcube Webmail installation |
|
| 50 |
+ |
|
| 51 |
+ - MAIL : |
|
| 52 |
+ The email address that will be notified on upgrade available (POSIX |
|
| 53 |
+ root user by default) |
|
| 54 |
+ |
|
| 55 |
+ - SEND_EVERY_NB_DAY : |
|
| 56 |
+ The frequency of upgrade available notification (in days, 7 by default) |
|
| 57 |
+ |
|
| 58 |
+ - CACHE : |
|
| 59 |
+ The path of a cache file use to keep the lastest upgrade notification. |
|
| 60 |
+ (By default : .cache_check_upgrade file in the parent directory of your |
|
| 61 |
+ Roundcube Webmail installation) |
|
| 62 |
+ |
|
| 63 |
+ - CACHE_FAILED : |
|
| 64 |
+ The path of a cache file use to keep the number of check failed. |
|
| 65 |
+ (By default : $CACHE suffix with '.failed') |
|
| 66 |
+ |
|
| 67 |
+ - MAX_CHECK : |
|
| 68 |
+ The maximum number of attempts to retreive current stable version on |
|
| 69 |
+ Roundcube Webmail Website. (10 by default) |
|
| 70 |
+ |
|
| 71 |
+ - MAX_FAILED : |
|
| 72 |
+ The maximum number of check failed before notify by email (3 by default) |
|
| 73 |
+ |
|
| 74 |
+ - SLEEP_ON_FAILED : |
|
| 75 |
+ The number of second to sleep between to attempts to retreive current |
|
| 76 |
+ stable version on Roundcube Webmail Website. (10 by default) |
|
| 77 |
+ |
|
| 78 |
+ - CHECK_URL : |
|
| 79 |
+ The URL use to retrieve the lastest Roundcube Webmail version. |
|
| 80 |
+ (By default : http://www.roundcube.net/download) |
|
| 81 |
+ |
|
| 82 |
+ - DOWNLOAD : |
|
| 83 |
+ If this variable is set to 1, the newest version will be automatically |
|
| 84 |
+ download in the download directory. (Default : 0) |
|
| 85 |
+ |
|
| 86 |
+ - DOWNLOAD_DIR : |
|
| 87 |
+ The path of the download directory. (Default : upstream directory in |
|
| 88 |
+ the parent directory of your Roundcube Webmail installation) |
|
| 0 | 89 |