Import owncloud from CCR.

This commit is contained in:
Jeff Huang 2014-12-24 00:13:38 +00:00
parent 2aa1fc41a6
commit bc9dff5901
3 changed files with 101 additions and 0 deletions

52
owncloud/PKGBUILD Normal file
View File

@ -0,0 +1,52 @@
# Maintainer: Jeff Huang <s8321414[at]gmail[dot]com>
# Origin maintainer on CCR: Giuseppe Calà <jiveaxe@gmail.com>
pkgname=owncloud
pkgver=7.0.4
pkgrel=2
pkgdesc="A cloud server to store your files centrally on a hardware controlled by you"
arch=('x86_64')
url="http://owncloud.org/"
license=('GPL')
depends=('php-gd' 'php-intl')
optdepends=('php-apache: to use the Apache web server'
'nginx: to use the nginx web server'
'php-sqlite: to use the SQLite database backend'
'php-pgsql: to use the PostgreSQL database backend'
'php-apcu'
'php-xcache'
'mariadb: to use the MySQL database backend'
'smbclient: to mount SAMBA shares'
'php-mcrypt'
'php-imagick: file preview'
'ffmpeg: file preview'
'libreoffice-common: file preview')
makedepends=()
categories=('network')
backup=('etc/httpd/conf/extra/owncloud.conf')
source=("http://download.owncloud.org/community/${pkgname}-${pkgver}.tar.bz2"
'owncloud.conf')
options=('!strip')
install=owncloud.install
md5sums=('6d4a3f9275d1f2b2607e7e6484051d4c'
'0505493fccf49dcaa0760268c290c138')
conflicts=('owncloud-git')
screenshot=(http://karlitschek.de/wp-content/uploads/2014/07/oc7.jpg)
package() {
# install license
install -d $pkgdir/usr/share/licenses/$pkgname
cp $srcdir/$pkgname/COPYING-* $pkgdir/usr/share/licenses/$pkgname
# install project
install -d ${pkgdir}/usr/share/webapps/
cp -a ${srcdir}/${pkgname} ${pkgdir}/usr/share/webapps/
chown -R http:http ${pkgdir}/usr/share/webapps/owncloud/{apps,config}
# install apache .conf file
install -d ${pkgdir}/etc/httpd/conf/extra
install -m 644 ${srcdir}/owncloud.conf ${pkgdir}/etc/httpd/conf/extra/
}

16
owncloud/owncloud.conf Normal file
View File

@ -0,0 +1,16 @@
<IfModule mod_alias.c>
Alias /owncloud /usr/share/webapps/owncloud/
</IfModule>
<Directory /usr/share/webapps/owncloud/>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
php_admin_value open_basedir "/srv/http/:/home/:/tmp/:/usr/share/pear/:/usr/share/webapps/"
</Directory>
<VirtualHost *:80>
ServerAdmin foo@myowncloud.com
DocumentRoot /usr/share/webapps/owncloud
ServerName myowncloud.com
ErrorLog logs/owncloud.info-error_log
CustomLog logs/owncloud.info-access_log common
</VirtualHost>

33
owncloud/owncloud.install Normal file
View File

@ -0,0 +1,33 @@
pkgname=ownCloud
post_install() {
echo "If you're using Apache web server add the following lines "
echo "into /etc/httpd/conf/httpd.conf:"
echo "Include conf/extra/owncloud.conf"
echo "LoadModule php5_module modules/libphp5.so"
echo "Include conf/extra/php5_module.conf"
echo
echo "Uncomment extensions:"
echo " extension=curl.so"
echo " extension=gd.so"
echo " extension=iconv.so"
echo " extension=intl.so"
echo " extension=openssl.so"
echo " extension=xmlrpc.so"
echo " extension=zip.so"
echo "in /etc/php/php.ini"
echo
echo "If you're using mysql database backend, uncomment also:"
echo " extension=mysql.so"
echo " extension=pdo_mysql.so"
echo
echo "Instead, if you're using sqlite database backend, uncomment:"
echo " extension=sqlite.so"
echo " extension=pdo_sqlite.so"
echo
}
post_upgrade()
{
post_install
}