-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
54 lines (41 loc) · 1.24 KB
/
Copy pathMakefile
File metadata and controls
54 lines (41 loc) · 1.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
.PHONY: up down restart build shell logs buildx-push buildx-multi certs
# Start the development environment
up:
ENABLE_HTTPS=$(ENABLE_HTTPS) docker-compose up -d
# Stop the development environment
down:
docker-compose down
# Restart the development environment
restart:
ENABLE_HTTPS=$(ENABLE_HTTPS) docker-compose restart
# Build the development environment
build:
ENABLE_HTTPS=$(ENABLE_HTTPS) docker-compose build --no-cache
# Enter the container shell
shell:
docker-compose exec app bash
# View logs
logs:
docker-compose logs -f
# Run artisan commands
artisan:
docker-compose exec app php artisan $(filter-out $@,$(MAKECMDGOALS))
# Run npm commands
npm:
docker-compose exec app npm $(filter-out $@,$(MAKECMDGOALS))
# Install dependencies
install:
docker-compose exec app composer install
docker-compose exec app npm install
# Generate SSL certificates for HTTPS
certs:
./generate-certs.sh
# Build with Buildx and push to registry
buildx-push:
ENABLE_HTTPS=$(ENABLE_HTTPS) ./build-push.sh --registry=$(REGISTRY) --tag=$(TAG)
# Build multi-platform images and push
buildx-multi:
ENABLE_HTTPS=$(ENABLE_HTTPS) ./build-push.sh --registry=$(REGISTRY) --tag=$(TAG) --platforms="linux/amd64,linux/arm64"
# Catch-all for passing arguments
%:
@: