Owncloud as virtualbox with mounted NAS

#
# Download owncloud Appliance
https://owncloud.org/install/#instructions-server

# import Machine to VirtualBox

VBoxManage import Ubuntu_14.04-owncloud-9.0.0-1.1-201603082006.ova --dry-run
VBoxManage import Ubuntu_14.04-owncloud-9.0.0-1.1-201603082006.ova

# Adjust name, cpu and memory 
# and start machine

VBoxManage controlvm <vmname> start

# Follow wizard to initial setup owncloud
# Create a new user

sudo adduser <username>
sudo adduser <username> sudo

# restart system
# login with new username and execute commands as root

sudo -i

# disable setup wizzard
# comment line: bash -x /var/scripts/check-init.sh; exit 0

vim /etc/rc.local

# add owncloud domain access

vim /var/www/owncloud/config/config.php

# goto <owncloud-domain> login as admin and enable some Apps as you wish
# Documents, Gallery

# Mount NAS for data

cp -prvf /var/www/owncloud/data /var/www/owncloud/data_orig
vim /etc/rc.local
mount -t cifs //10.1.5.51/owncloud /var/www/owncloud/data -o username=<nasuser>,password=<naspasswd>,iocharset=utf8,file_mode=0770,dir_mode=0770,uid=33,gid=1000
cp -prvf /var/www/owncloud/data_orig/* /var/www/owncloud/data
rm -R /var/www/owncloud/data_orig

todo: manage users by REST API
 

Free Tags: