forked from openfaas/cron-connector
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
28 lines (23 loc) · 1.18 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
.PHONY: build push manifest test verify-codegen charts
TAG?=latest
# docker manifest command will work with Docker CLI 18.03 or newer
# but for now it's still experimental feature so we need to enable that
export DOCKER_CLI_EXPERIMENTAL=enabled
build:
docker build -t openfaas/cron-connector:$(TAG)-amd64 . -f Dockerfile
docker build --build-arg OPTS="GOARCH=arm64" -t openfaas/cron-connector:$(TAG)-arm64 . -f Dockerfile
docker build --build-arg OPTS="GOARCH=arm GOARM=6" -t openfaas/cron-connector:$(TAG)-armhf . -f Dockerfile
push:
docker push openfaas/cron-connector:$(TAG)-amd64
docker push openfaas/cron-connector:$(TAG)-arm64
docker push openfaas/cron-connector:$(TAG)-armhf
manifest:
docker manifest create --amend openfaas/cron-connector:$(TAG) \
openfaas/cron-connector:$(TAG)-amd64 \
openfaas/cron-connector:$(TAG)-arm64 \
openfaas/cron-connector:$(TAG)-armhf
docker manifest annotate openfaas/cron-connector:$(TAG) openfaas/cron-connector:$(TAG)-arm64 --os linux --arch arm64
docker manifest annotate openfaas/cron-connector:$(TAG) openfaas/cron-connector:$(TAG)-armhf --os linux --arch arm --variant v6
docker manifest push -p openfaas/cron-connector:$(TAG)
test:
go test ./...