Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- set -e
- set -v
- if (! owncloudcmd ) ; then
- wget http://download.opensuse.org/repositories/isv:ownCloud:desktop/Ubuntu_14.04/Release.key
- sudo apt-key add - < Release.key
- sudo sh -c "echo 'deb http://download.opensuse.org/repositories/isv:/ownCloud:/desktop/Ubuntu_14.04/ /' > /etc/apt/sources.list.d/owncloud-client.list"
- sudo apt-get -y update
- sudo apt-get -y -f install owncloud-client
- fi
- mkdir -p ~/bin
- CONF=~/bin/owncloud_user.conf
- if (! stat "${CONF}" ) ; then
- cat > "${CONF}" << HERE
- # Please update this file to reflect the correct authentification data
- # then type <ESC>:wq<ENTER> to save these settings
- USER=test
- PASS=test
- SERVER=https://example.org
- DIR=~/signage
- HERE
- fi
- rm -rf ${DIR}
- while (! stat ${DIR}/Programm/install.sh) ; do
- vi "${CONF}"
- eval "$(cat ${CONF})"
- mkdir -p ${DIR}
- owncloudcmd --silent --user "${USER}" --password "${PASS}" "${DIR}" "${SERVER}"
- done
- cd ${DIR}/Programm
- chmod +x install.sh
- ./install.sh
- set +v
- echo "***********************************************"
- echo "Installation was successful. Please restart the"
- echo "machine by typing: sudo telinit 6"
- echo "***********************************************"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement