zammad-docker-compose/install-zammad.sh

19 lines
812 B
Bash
Raw Normal View History

#!/bin/bash
2017-01-09 17:52:52 +00:00
set -e
# install zammad
echo "installing zammad..."
2017-01-09 17:52:52 +00:00
cd /tmp
2017-01-09 16:39:11 +00:00
git clone --depth 1 -b "${GIT_BRANCH}" "${GIT_URL}"
cp -R /tmp/zammad/* "${ZAMMAD_DIR}"
cp -R /tmp/zammad/.[!.]* "${ZAMMAD_DIR}"
2017-01-09 17:52:52 +00:00
cd "${ZAMMAD_DIR}"
rm -rf /tmp/zammad
bundle install --without test development mysql
2017-01-09 17:28:32 +00:00
contrib/packager.io/fetch_locales.rb
sed -e 's#.*adapter: postgresql# adapter: nulldb#g' -e 's#.*username:.*# username: postgres#g' -e 's#.*password:.*# password: \n host: postgresql\n#g' < config/database.yml.pkgr > config/database.yml
bundle exec rake assets:precompile
sed -e 's#.*adapter: postgresql# adapter: postgresql#g' -e 's#.*username:.*# username: postgres#g' -e 's#.*password:.*# password: \n host: postgresql\n#g' < config/database.yml.pkgr > config/database.yml
2017-01-09 16:39:11 +00:00
chown -R zammad:zammad "${ZAMMAD_DIR}"