2016-08-28 07:58:27 +00:00
|
|
|
#! /bin/sh
|
|
|
|
|
|
|
|
# setup
|
2016-09-11 06:10:38 +00:00
|
|
|
sudo npm install -g bower
|
|
|
|
sudo --askpass bower install --allow-root
|
2016-09-11 06:12:38 +00:00
|
|
|
gem install bundler
|
2016-08-28 07:58:27 +00:00
|
|
|
bundle install
|
|
|
|
bin/rake db:migrate
|
|
|
|
|
|
|
|
# make configuration file
|
2016-09-08 08:51:24 +00:00
|
|
|
|
2016-08-28 07:58:27 +00:00
|
|
|
CONF_PATH=`pwd`/configure.conf
|
2016-09-08 08:51:24 +00:00
|
|
|
|
2016-09-11 06:10:38 +00:00
|
|
|
if ls `pwd` | grep configure.conf; then
|
2016-09-08 08:51:24 +00:00
|
|
|
echo "configure.conf exist"
|
|
|
|
else
|
2016-08-28 07:58:27 +00:00
|
|
|
touch $CONF_PATH
|
|
|
|
echo "project_path=`pwd`" >> $CONF_PATH
|
|
|
|
echo "server_name=gluster" >> $CONF_PATH
|
|
|
|
echo "host_ip=127.0.0.1" >> $CONF_PATH
|
2016-08-28 08:36:02 +00:00
|
|
|
echo "host_port=" >> $CONF_PATH
|
2016-08-28 07:58:27 +00:00
|
|
|
echo "host_user=root" >> $CONF_PATH
|
|
|
|
echo "host_password=secret" >> $CONF_PATH
|
2016-09-08 08:51:24 +00:00
|
|
|
fi
|