gemma4-stack / Makefile
Neohosseinism's picture
Add gemma4-stack config, scripts, and docker-compose setup
89bf59d
Raw
History Blame Contribute Delete
1.09 kB
# Minimal helpers for the Gemma 4 stack. Run `make help`.
ENV ?= dev-cpu
ARGS ?=
COMPOSE = docker compose
.PHONY: help env models pull up up-gpu down ps logs test clean
help: ## Show this help
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | \
awk 'BEGIN{FS=":.*?## "}{printf " \033[36m%-10s\033[0m %s\n",$$1,$$2}'
env: ## Copy profiles/$(ENV).env -> .env (ENV=dev-cpu|cpu-server|cpu-server-xl|gpu)
cp profiles/$(ENV).env .env
models: ## Download required BF16 mmproj (use ARGS=--weights to also fetch GGUFs)
./scripts/download-models.sh $(ARGS)
pull: ## Pre-pull docker images
$(COMPOSE) pull
up: ## Start the CPU stack
$(COMPOSE) up -d
up-gpu: ## Start the GPU stack (needs profiles/gpu.env)
$(COMPOSE) -f docker-compose.yml -f docker-compose.gpu.yml up -d
down: ## Stop the stack
$(COMPOSE) down
ps: ## Show service status
$(COMPOSE) ps
logs: ## Tail logs (SVC=llama-swap to filter)
$(COMPOSE) logs -f --tail=120 $(SVC)
test: ## Run the e2e smoke tests
./scripts/e2e-test.sh
clean: ## Stop and remove containers + volumes
$(COMPOSE) down -v