Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- PANDUAN INSTALLASI
- ======================================================
- #apt-get install mariadb-server mariadb-client apache2 libapache2-mod-php5 php5-json php5-gd php5-mysql php5-curl php5-intl php5-mcrypt php5-imagick
- ======================================================
- #wget https://download.owncloud.org/community/owncloud-9.0.0.tar.bz2
- ======================================================
- #tar xjvf owncloud-9.0.0.tar.bz2
- ======================================================
- #cp -R owncloud /var/www
- ======================================================
- #cp /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/owncloud.conf
- ======================================================
- #nano etc/apache2/sites-available/owncloud.conf
- ======================================================
- Alias /owncloud "/var/www/owncloud/"
- <Directory /var/www/owncloud/>
- Options +FollowSymlinks
- AllowOverride All
- <IfModule mod_dav.c>
- Dav off
- </IfModule>
- SetEnv HOME /var/www/owncloud
- SetEnv HTTP_HOME /var/www/owncloud
- </Directory>
- ======================================================
- #a2ensite owncloud
- #a2enmod rewrite
- #a2enmod headers
- #a2dissite 000-default.conf
- #service apache2 restart
- #chown -R www-data:www-data /var/www/owncloud/
- #nano oc-perms.sh
- ===================================================
- #!/bin/bash
- ocpath='/var/www/owncloud'
- htuser='www-data'
- htgroup='www-data'
- rootuser='root'
- printf "Creating possible missing Directories\n"
- mkdir -p $ocpath/data
- mkdir -p $ocpath/assets
- printf "chmod Files and Directories\n"
- find ${ocpath}/ -type f -print0 | xargs -0 chmod 0640
- find ${ocpath}/ -type d -print0 | xargs -0 chmod 0750
- printf "chown Directories\n"
- chown -R ${rootuser}:${htgroup} ${ocpath}/
- chown -R ${htuser}:${htgroup} ${ocpath}/apps/
- chown -R ${htuser}:${htgroup} ${ocpath}/config/
- chown -R ${htuser}:${htgroup} ${ocpath}/data/
- chown -R ${htuser}:${htgroup} ${ocpath}/themes/
- chown -R ${htuser}:${htgroup} ${ocpath}/assets/
- chmod +x ${ocpath}/occ
- printf "chmod/chown .htaccess\n"
- if [ -f ${ocpath}/.htaccess ]
- then
- chmod 0644 ${ocpath}/.htaccess
- chown ${rootuser}:${htgroup} ${ocpath}/.htaccess
- fi
- if [ -f ${ocpath}/data/.htaccess ]
- then
- chmod 0644 ${ocpath}/data/.htaccess
- chown ${rootuser}:${htgroup} ${ocpath}/data/.htaccess
- fi
- ======================================================
- #chmod u+x oc-perms.sh
- #oc-perms
- #mysql -u root -p
- mysql> create database owncloud;
- mysql> create user admin@localhost identified by 'tkj';
- mysql> grant all privileges on owncloud.* to admin@localhost identified by 'tkj';
- mysql> flush privileges;
- mysql> quit
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement