Skip to content

feat: initial colima support #647

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -54,6 +54,9 @@ export PATH := $(TOOLS_D)/bin:$(PATH)
GOLANGCI_LINT_VERSION = v1.54.2
GOLANGCI_LINT = $(TOOLS_D)/golangci-lint/$(GOLANGCI_LINT_VERSION)/golangci-lint

COLIMA_VERSION = v0.7.5
COLIMA = $(TOOLS_D)/colima/$(COLIMA_VERSION)/colima

STAGE1_STACKER ?= ./stacker-dynamic

STACKER_DEPS = $(GO_SRC) go.mod go.sum
@@ -122,14 +125,21 @@ go-test:
go tool cover -html coverage.txt -o $(HACK_D)/coverage.html

.PHONY: download-tools
download-tools: $(GOLANGCI_LINT) $(REGCLIENT) $(ZOT) $(BATS)
download-tools: $(COLIMA) $(GOLANGCI_LINT) $(REGCLIENT) $(ZOT) $(BATS)

$(GOLANGCI_LINT):
@mkdir -p $(dir $@)
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b "$(dir $@)"
@mkdir -p "$(TOOLS_D)/bin"
ln -sf "$@" "$(TOOLS_D)/bin/"

$(COLIMA):
@mkdir -p $(dir $@)
# download binary
curl -Lo "$@" https://github.com/abiosoft/colima/releases/download/$(COLIMA_VERSION)/colima-$(shell uname)-$(shell uname -m)
@mkdir -p "$(TOOLS_D)/bin"
ln -sf "$@" "$(TOOLS_D)/bin/"

# dlbin is used with $(call dlbin,path,url)
# it downloads a url to path and makes it executable.
# it creates dest dir and atomically moves into place. t gets <name>.pid