1
0
forked from pool/roundcubemail
Wolfgang Rosenauer 2012-05-12 22:09:12 +00:00 committed by Git OBS Bridge
parent 4229941ffc
commit 65bc6a5d95
4 changed files with 86 additions and 11 deletions

53
README.openSUSE Normal file
View File

@ -0,0 +1,53 @@
This README contains additional information specific to the
openSUSE package of roundcube.
INSTALLATION
============
This application is packaged to integrate with Apache and MySQL but
it can basically run with every webserver being able to run PHP and
also use other SQL based database engines.
After installation of the package the application will immediately
be reachable from everywhere once Apache is enabled under the URL
http://IP-ADDRESS/roundcube
The configuration is copied from the example config files from the
package and therefore not really working.
First step is to prepare the MySQL database for Roundcube:
Setting up the mysql database can be done by creating an empty database,
importing the table layout and granting the proper permissions to the
roundcube user. Here is an example of that procedure:
# mysql
> CREATE DATABASE roundcubemail /*!40101 CHARACTER SET utf8 COLLATE utf8_general_ci */;
> GRANT ALL PRIVILEGES ON roundcubemail.* TO roundcube@localhost
IDENTIFIED BY 'password';
> quit
# mysql roundcubemail < /srv/www/roundcubemail/SQL/mysql.initial.sql
Note 1: 'password' is the master password for the roundcube user. It is strongly
recommended you replace this with a more secure password. Please keep in
mind: You need to specify this password later in '/etc/roundcubemail/db.inc.php'.
To use the integrated web based installer you need to enable it first
in /etc/roundcubemail/main.inc.php:
$rcmail_config['enable_installer'] = true;
IMPORTANT: This MUST be disabled again after installation is finished
for SECURITY reasons
and then access
http://IP-ADDRESS/roundcube/installer
to finish the installation.

View File

@ -17,8 +17,8 @@ AddType text/x-component .htc
<Directory __ROUNDCUBEPATH__>
Order allow,deny
Allow from 127.0.0.1
#Allow from all
#Allow from 127.0.0.1
Allow from all
Options -Indexes FollowSymLinks

View File

@ -1,3 +1,16 @@
-------------------------------------------------------------------
Sat May 12 17:59:17 UTC 2012 - wr@rosenauer.org
- added README.openSUSE to document openSUSE specifics needed for
installation/configuration
-------------------------------------------------------------------
Mon Apr 30 13:50:22 UTC 2012 - wr@rosenauer.org
- enable Roundcube access from everywhere by default after
installation
- ship *.dist configuration files
-------------------------------------------------------------------
Sun Apr 15 18:38:01 UTC 2012 - wr@rosenauer.org

View File

@ -36,11 +36,14 @@ Requires: php-openssl
Requires: php-session
Requires: php_any_db
Recommends: php-mysql
Recommends: php5-intl
Recommends: php5-fileinfo
## Requires: for upstream dep package
#Requires: php5-intl php5-pear-Auth_SASL
#Requires: php5-pear-Auth_SASL
Source0: %{name}-%{version}.tar.gz
Source2: %{name}-httpd.conf
Source3: %{name}-rpmlintrc
Source4: README.openSUSE
# PATCH-FIX-OPENSUSE use the general config directory /etc
Patch0: %{name}-config-dir.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
@ -63,6 +66,7 @@ The user interface is fully skinnable using XHTML and CSS 2.
%prep
%setup -q -n %{name}-%{version}
%patch0 -p1
cp %{SOURCE4} .
%build
@ -70,10 +74,9 @@ The user interface is fully skinnable using XHTML and CSS 2.
install -d -m 0755 %buildroot%roundcubepath
cp -a * %buildroot%{roundcubepath}/
mkdir -p %buildroot/%_sysconfdir/%name
cp config/db.inc.php.dist %buildroot/%{roundcubeconfigpath}/db.inc.php
cp config/main.inc.php.dist %buildroot/%{roundcubeconfigpath}/main.inc.php
cp config/* %buildroot/%{roundcubeconfigpath}/
rm %{buildroot}%{roundcubeconfigpath}/*.dist
cp %buildroot/%{roundcubeconfigpath}/main.inc.php.dist %buildroot/%{roundcubeconfigpath}/main.inc.php
cp %buildroot/%{roundcubeconfigpath}/db.inc.php.dist %buildroot/%{roundcubeconfigpath}/db.inc.php
rm -rf %buildroot%{roundcubepath}/config
# install httpd.conf file and adapt the configuration
@ -82,7 +85,7 @@ sed -e "s#__ROUNDCUBEPATH__#%{roundcubepath}#g" %{SOURCE2} > %buildroot%{apache_
# install docs
install -d -m 0755 %buildroot%_defaultdocdir/%name
for i in CHANGELOG INSTALL UPGRADING LICENSE README ; do
for i in CHANGELOG INSTALL UPGRADING LICENSE README README.openSUSE; do
mv -v %{buildroot}%{roundcubepath}/$i %{buildroot}%{_defaultdocdir}/%name/
done
@ -97,19 +100,25 @@ rm -rf %buildroot
%post
# enable apache required apache modules
if [ -x /usr/sbin/a2enmod ]
then
if [ -x /usr/sbin/a2enmod ]; then
a2enmod -q alias || a2enmod alias
a2enmod -q rewrite || a2enmod rewrite
fi
if [ ! -f %{roundcubeconfigpath}/main.inc.php ]; then
cp %{roundcubeconfigpath}/main.inc.php.dist %{roundcubeconfigpath}/main.inc.php
fi
if [ ! -f %{roundcubeconfigpath}/db.inc.php ]; then
cp %{roundcubeconfigpath}/db.inc.php.dist %{roundcubeconfigpath}/db.inc.php
fi
exit 0
%files
%defattr(0644, root, root,0755)
%doc %_defaultdocdir/%name/
%dir %{roundcubepath}
%dir %{roundcubeconfigpath}
%config(noreplace) %{roundcubeconfigpath}/db.inc.php
%config(noreplace) %{roundcubeconfigpath}/main.inc.php
%ghost %config(noreplace) %{roundcubeconfigpath}/db.inc.php
%ghost %config(noreplace) %{roundcubeconfigpath}/main.inc.php
%config %{roundcubeconfigpath}/*
%config %{roundcubeconfigpath}/mimetypes.php
%config(noreplace) %{apache_sysconfdir}/conf.d/roundcubemail.conf