Skip to content

Commit

Permalink
Added make targets for deployment and cron service start
Browse files Browse the repository at this point in the history
  • Loading branch information
icarito committed May 24, 2018
1 parent ef54ef4 commit 8c97137
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,21 @@
build:
cp config/database.yml.example config/database.yml
cp db/schema.rb.example db/schema.rb
docker-compose down --remove-orphans
docker-compose build

deploy-container:
docker-compose run web sleep 5
docker-compose run web rake db:migrate
docker-compose run web bower install --allow-root
docker-compose run web bower update --allow-root
docker-compose run web rake assets:precompile
test -e tmp/pids/server.pid && rm tmp/pids/server.pid
docker-compose up -d
docker-compose exec -T web bash -c "echo 172.19.0.1 smtp >> /etc/hosts"
docker-compose exec -T web bundle exec whenever --update-crontab
docker-compose exec -T web service start cron

install-dev:
echo "Installing RubyGems"
bundle install --without production mysql
Expand Down

0 comments on commit 8c97137

Please sign in to comment.