-
Notifications
You must be signed in to change notification settings - Fork 56
/
Makefile
29 lines (22 loc) · 996 Bytes
/
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
test:
python3 -m unittest discover -s tests -v
TMP_PCI_IDS = /tmp/ocboot-pci.ids
DEST_PCI_IDS = $(CURDIR)/onecloud/roles/utils/gpu-init/files/pci.ids
OLD_VERSION?=
update-pciids:
curl -o $(TMP_PCI_IDS) http://pci-ids.ucw.cz/v2.2/pci.ids && \
mv $(TMP_PCI_IDS) $(DEST_PCI_IDS)
.PHONY: test
REGISTRY ?= "registry.cn-beijing.aliyuncs.com/yunionio"
VERSION ?= v4-k3s.4
image:
docker buildx build --platform linux/arm64,linux/amd64 --push \
-t $(REGISTRY)/ocboot:$(VERSION) -f ./Dockerfile .
generate-docker-compose-manifests:
VERSION=$(VERSION) python3 ./generate-compose.py > ./compose/docker-compose.yml
@if [ -n "$(OLD_VERSION)" ] && [ -n "$(VERSION)" ]; then \
perl -pi -e "s#$(OLD_VERSION)#$(VERSION)#" $$(find . -type f \( -iname \*.py -o -iname \*.yaml -o -iname \*.sh -o -iname VERSION \) ! -path "./.git/*" ); \
fi
generate-baremetal-compose-manifests:
VERSION=$(VERSION) PRODUCT_VERSION=Baremetal \
python3 ./generate-compose.py > compose/baremetal/docker-compose.yml