-
-
Notifications
You must be signed in to change notification settings - Fork 18
/
Makefile
55 lines (42 loc) · 1.85 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
53
54
55
# Include toolbox tasks
include ./.toolbox.mk
# Run go fmt against code
fmt: tb.golangci-lint
$(TB_GOLANG_CI_LINT) run --fix
# Run go mod tidy
tidy:
go mod tidy
# Run tests
test: mocks tidy fmt helm-lint test-cover
# Run coverage tests
test-cover: tb.ginkgo
$(TB_GINKGO) --cover ./...
release: tb.goreleaser tb.semver
@version=$$($(TB_SEMVER)); \
git tag -s $$version -m"Release $$version"
$(TB_GORELEASER) --clean
test-release: tb.goreleaser
$(TB_GORELEASER) --skip=publish --snapshot --clean
mocks: tb.mockgen
$(TB_MOCKGEN) -destination pkg/mocks/core/mock.go --package core k8s.io/client-go/kubernetes/typed/core/v1 CoreV1Interface,SecretInterface
$(TB_MOCKGEN) -destination pkg/mocks/ssclient/mock.go --package ssclient github.com/bitnami-labs/sealed-secrets/pkg/client/clientset/versioned/typed/sealedsecrets/v1alpha1 BitnamiV1alpha1Interface,SealedSecretInterface
$(TB_MOCKGEN) -destination pkg/mocks/seal/mock.go --package seal github.com/bakito/sealed-secrets-web/pkg/seal Sealer
build:
podman build --build-arg VERSION=dev --build-arg BUILD=dev --build-arg TARGETPLATFORM=linux/amd64 -t sealed-secrets-web .
build-arm:
podman build --build-arg VERSION=dev --build-arg BUILD=dev --build-arg TARGETPLATFORM=linux/arm64 -t sealed-secrets-web .
helm-docs: tb.helm-docs update-chart-version
@$(TB_HELM_DOCS)
update-chart-version: tb.semver
@version=$$($(TB_SEMVER) -next); \
versionNum=$$($(TB_SEMVER) -next -numeric); \
sed -i "s/^version:.*$$/version: $${versionNum}/" ./chart/Chart.yaml; \
sed -i "s/^appVersion:.*$$/appVersion: $${version}/" ./chart/Chart.yaml
helm-lint: helm-docs
helm lint ./chart
helm-template:
helm template ./chart -n sealed-secrets-web
@echo "#######################"
helm template ./chart -n sealed-secrets-web --set disableLoadSecrets=true --set sealedSecrets.serviceName=
helm-chainsaw:
./testdata/e2e/chainsaw/run.sh