forked from CODEBASE-Okinawa/codebase_books_kame
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
19 lines (15 loc) · 623 Bytes
/
Makefile
File metadata and controls
19 lines (15 loc) · 623 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
.DEFAULT_GOAL := help
build: ## build develoment environment
if ! [ -f .env ];then cp .env.sample .env;fi
docker-compose build
docker-compose run --rm app bundle install
docker-compose run --rm app bin/rails db:create
docker-compose run --rm app bin/rails db:schema:load
docker-compose run --rm app bin/rails db:seed
serve: ## Run Server
docker-compose up app
db-log: ## Tail mariadb log
docker-compose exec mysql tail -f /var/log/mysql/mysql-query.log
.PHONY: help
help:
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'