Skip to content

Commit

Permalink
Merge pull request #305 from mycookbook/small-improvements
Browse files Browse the repository at this point in the history
Add a make cmd to build and push the application as an image to the r…
  • Loading branch information
fokosun authored Nov 25, 2023
2 parents 21e454a + 68aec68 commit 061a84d
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,22 @@ help:
@printf "\033[33mUsage:\033[0m\n make [target] [arg=\"val\"...]\n\n\033[33mTargets:\033[0m\n"
@grep -E '^[-a-zA-Z0-9_\.\/]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf " \033[32m%-15s\033[0m %s\n", $$1, $$2}'

install: copy_env down build up setup
install: copy_env down build up setup

down: ## Destroy the containers
@docker-compose down

build: ## build the containers
@docker-compose build

build_and_push: docker_build_image docker_push_image

docker_build_image:
@docker build -t fokosun/cookbookshq-api:v1 .

docker_push_image:
@docker push fokosun/cookbookshq-api:v1

db_seed: ## seed the database
@php artisan db:seed

Expand Down

0 comments on commit 061a84d

Please sign in to comment.