diff options
author | Jakub Jirutka <jakub@jirutka.cz> | 2018-07-26 19:48:10 +0200 |
---|---|---|
committer | Jakub Jirutka <jakub@jirutka.cz> | 2018-07-27 15:30:37 +0200 |
commit | 932c29484953c97c27739246e25ef64e27ce3619 (patch) | |
tree | 567b082426d306ec41220f5aaab0598f1c9dd308 /community | |
parent | 1436d065e474654e27cdec08c4198cfc6776f23b (diff) | |
download | aports-932c29484953c97c27739246e25ef64e27ce3619.tar.bz2 aports-932c29484953c97c27739246e25ef64e27ce3619.tar.xz |
community/roundcubemail: fix fixing of paths, remove ancient mess
- These pre/post upgrade scripts has been added 8 years ago, so they
are not needed anymore.
- The pre-upgrade script is even not used.
- The sed in prepare breaks config.
Diffstat (limited to 'community')
-rw-r--r-- | community/roundcubemail/APKBUILD | 8 | ||||
-rw-r--r-- | community/roundcubemail/fix-dirs.patch | 24 | ||||
-rw-r--r-- | community/roundcubemail/roundcubemail.post-upgrade | 40 | ||||
-rw-r--r-- | community/roundcubemail/roundcubemail.pre-upgrade | 7 |
4 files changed, 15 insertions, 64 deletions
diff --git a/community/roundcubemail/APKBUILD b/community/roundcubemail/APKBUILD index b130fd242d..24617a22f0 100644 --- a/community/roundcubemail/APKBUILD +++ b/community/roundcubemail/APKBUILD @@ -55,12 +55,6 @@ prepare() { # remove .htaccess find . -name \.htaccess -print | xargs rm -f - # fixup paths to use the right paths - sed -i -e 's|temp/|/tmp/|' \ - -e 's|config/|/etc/roundcube/|' \ - -e 's|logs/|/var/log/roundcube/|' \ - config/defaults.inc.php - # cleanup sed -i 's/\r//' SQL/mssql.initial.sql rm -rf logs temp @@ -99,4 +93,4 @@ _mv() { } sha512sums="c5e1e80034392ea4fcf780750ad2b7db43422a746462015865cbdb027e9e47b2bae7b191da19b65a7b9303c195bdfd0aa5b5a0382c09dd97d117671271cdc122 roundcubemail-1.3.6.tar.gz -a8dc9e9493f9b24441378f6a526eb26e4dd4b0ef0cafaf25dd55c334b92df88dcb06008f46404a80eae0520ac04431c5b2237fd662c85c31fc6ee2b0d8fa9435 fix-dirs.patch" +d205ba8442870b26f93fb287e7fe2bd1a452ea534823869b7ef299e2dca52d64c8a3fdc9a44bd3bc731c1e400efcf745c1866974e3b908e4e54d05b47b835f3e fix-dirs.patch" diff --git a/community/roundcubemail/fix-dirs.patch b/community/roundcubemail/fix-dirs.patch index bb0f809c35..3d0807fb15 100644 --- a/community/roundcubemail/fix-dirs.patch +++ b/community/roundcubemail/fix-dirs.patch @@ -1,15 +1,19 @@ ---- a/config/config.inc.php.sample -+++ b/config/config.inc.php.sample -@@ -84,3 +84,9 @@ +--- a/config/defaults.inc.php ++++ b/config/defaults.inc.php +@@ -382,11 +382,11 @@ + // use this folder to store log files + // must be writeable for the user who runs PHP process (Apache user if mod_php is being used) + // This is used by the 'file' log driver. +-$config['log_dir'] = RCUBE_INSTALL_PATH . 'logs/'; ++$config['log_dir'] = '/var/log/roundcube'; - // skin name: folder from skins/ - $config['skin'] = 'larry'; -+ -+// Temporary directory + // use this folder to store temp files + // must be writeable for the user who runs PHP process (Apache user if mod_php is being used) +-$config['temp_dir'] = RCUBE_INSTALL_PATH . 'temp/'; +$config['temp_dir'] = '/tmp'; -+ -+// Log directory -+$config['log_dir'] = '/var/log/roundcube'; + + // expire files in temp_dir after 48 hours + // possible units: s, m, h, d, w --- a/program/include/iniset.php +++ b/program/include/iniset.php @@ -29,7 +29,7 @@ diff --git a/community/roundcubemail/roundcubemail.post-upgrade b/community/roundcubemail/roundcubemail.post-upgrade index a6282906a0..7557e4178f 100644 --- a/community/roundcubemail/roundcubemail.post-upgrade +++ b/community/roundcubemail/roundcubemail.post-upgrade @@ -1,45 +1,5 @@ #!/bin/sh -# move existing config in /usr/share/webapps/roundcube/config to -# /etc/roundcube and create a symlink in /usr/share/webapps/roundcube that -# points to /etc/roundcube dir. - -# if we did this in pre-upgrade, apk would delete -# /usr/share/webapps/roundcube/config/* which would actually point to -# /etc/roundcube due to symlink. oups! - -if [ -L /usr/share/webapps/roundcube/config.apk-new ] && \ - [ -d /usr/share/webapps/roundcube/config ]; then - mkdir -p /etc/roundcube - # if configs were unmodified they are deleted by apk - # so we check if they exist before trying to move anything - for i in /usr/share/webapps/roundcube/config/* \ - /usr/share/webapps/roundcube/config/.[A-z]*; do - if [ -f "$i" ]; then - mv "$i" /etc/roundcube - fi - done - rmdir /usr/share/webapps/roundcube/config - mv /usr/share/webapps/roundcube/config.apk-new \ - /usr/share/webapps/roundcube/config -fi - -# logs and temp moved -if [ -d /usr/share/webapps/roundcube/logs ]; then - mv /usr/share/webapps/roundcube/logs/* \ - /var/log/roundcube/ - - # clone permissions - chown $(stat -c %U:%G /usr/share/webapps/roundcube/logs) \ - /var/log/roundcube -fi - -if [ -d /usr/share/webapps/roundcube/temp ]; then - mv /usr/share/webapps/roundcube/temp/* \ - /tmp/ -fi - -# display info about upgrade echo "*" >&2 echo -e "* Please read /usr/share/doc/roundcube/UPGRADE\n\ * in roundcubemail-doc package for schema or config update" >&2 diff --git a/community/roundcubemail/roundcubemail.pre-upgrade b/community/roundcubemail/roundcubemail.pre-upgrade deleted file mode 100644 index 1d44a87034..0000000000 --- a/community/roundcubemail/roundcubemail.pre-upgrade +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/sh - -if [ -d /usr/share/webapps/roundcube/config ]; then - mkdir -p /etc - mv /usr/share/webapps/roundcube/config /etc/roundcube -fi - |