This repository has been archived on 2024-04-29. You can view files and clone it, but cannot push or open issues or pull requests.
node-fftcg/Makefile

30 lines
827 B
Makefile

COMPOSE:=sudo docker-compose
.PHONY: all
all: develop
%/node_modules/.yarn-integrity:
$(eval image:=$(patsubst %/node_modules/.yarn-integrity,%,$@))
$(COMPOSE) build $(image)
$(COMPOSE) run --rm $(image) yarn install --production=false
DFILES:=$(wildcard */Dockerfile)
IMAGES:=$(patsubst %/Dockerfile,%,$(DFILES))
.PHONY: develop
develop: $(patsubst %,%/node_modules/.yarn-integrity,$(IMAGES))
$(COMPOSE) up
.PHONY: production
production:
$(COMPOSE) -f docker-compose.yml -f docker-compose.prod.yml build
$(COMPOSE) -f docker-compose.yml -f docker-compose.prod.yml up -d
.PHONY: fe-init fe-init-simple
fe-init:
$(COMPOSE) build frontend
$(COMPOSE) run --rm frontend vue init bootstrap-vue/webpack .
fe-init-simple:
$(COMPOSE) build frontend
$(COMPOSE) run --rm frontend vue init bootstrap-vue/webpack-simple .