-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
52 lines (36 loc) · 1.9 KB
/
Makefile
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
include common.Makefile
.PHONY: prepare docker-login all base extensions release
prepare:
#sudo apt-get update && sudo apt-get install -y qemu-user-static binfmt-support make
docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
docker buildx create --platform "linux/amd64,linux/arm64" --use
docker-login:
echo ${GITHUB_TOKEN} | docker login ghcr.io -u ${GITHUB_USER} --password-stdin
all:
$(MAKE) base RELEASE=$(RELEASE) REPO=$(REPO)
$(MAKE) extensions RELEASE=$(RELEASE) REPO=$(REPO)
base: # Build the custom extensions
cd src/base ; $(MAKE) build RELEASE=$(RELEASE) REPO=$(REPO)
extensions: # Build the custom extensions
cd src/extensions ; $(MAKE) build RELEASE=$(RELEASE) REPO=$(REPO)
cd src/envs ; $(MAKE) build RELEASE=$(RELEASE) REPO=$(REPO)
## Dev stuff
dev-base-%: # Build a release version for a specific extension
cd src/base ; $(MAKE) build-$* RELEASE=$(RELEASE) REPO=$(REPO)
dev-extension-%: # Build a release version for a specific extension
cd src/extensions ; $(MAKE) ext-$* RELEASE=$(RELEASE) REPO=$(REPO)
dev-env-%: # Build a release version for a specific environment
cd src/envs ; $(MAKE) env-$* RELEASE=$(RELEASE) REPO=$(REPO)
## Release stuff
release: # Build a release version
$(MAKE) all RELEASE=$(RELEASE) REPO=$(PROD_REPO)
release-base: # Build a release version for the base containers
$(MAKE) base RELEASE=$(RELEASE) REPO=$(PROD_REPO)
release-extensions: # Build a release version for the extensions
$(MAKE) extensions RELEASE=$(RELEASE) REPO=$(PROD_REPO)
release-base-%: # Build a release version for a specific extension
cd src/base ; $(MAKE) build-$* RELEASE=$(RELEASE) REPO=$(PROD_REPO)
release-extension-%: # Build a release version for a specific extension
cd src/extensions ; $(MAKE) ext-$* RELEASE=$(RELEASE) REPO=$(PROD_REPO)
release-env-%: # Build a release version for a specific environment
cd src/envs ; $(MAKE) env-$* RELEASE=$(RELEASE) REPO=$(PROD_REPO)