-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
33 lines (24 loc) · 947 Bytes
/
Makefile
File metadata and controls
33 lines (24 loc) · 947 Bytes
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
SHORT_NAME := storage
IMAGE_PREFIX ?= drycc
# podman development environment variables
REPO_PATH := github.com/drycc/${SHORT_NAME}
DEV_ENV_IMAGE := ${DEV_REGISTRY}/drycc/go-dev
DEV_ENV_WORK_DIR := /workspace
DEV_ENV_PREFIX := podman run --env CGO_ENABLED=0 --rm -v ${CURDIR}:${DEV_ENV_WORK_DIR} -w ${DEV_ENV_WORK_DIR}
DEV_ENV_CMD := ${DEV_ENV_PREFIX} ${DEV_ENV_IMAGE}
DRYCC_REGISTRY ?= ${DEV_REGISTRY}
SHELL_SCRIPTS = $(wildcard _tests/*.sh)
include versioning.mk
all: podman-build podman-push
test: test-style podman-build
_tests/test.sh
test-style:
${DEV_ENV_CMD} shellcheck $(SHELL_SCRIPTS)
podman-build:
# build the main image
podman build --build-arg CODENAME=${CODENAME} -t ${IMAGE} .
podman tag ${IMAGE} ${MUTABLE_IMAGE}
podman-buildx:
podman buildx build --build-arg CODENAME=${CODENAME} --platform ${PLATFORM} -t ${IMAGE} . --push
deploy: build podman-build podman-push
.PHONY: all bootstrap build test podman-build deploy