@@ -6,6 +6,7 @@ BUILD_TIME:=$(shell date 2>/dev/null)
66TAG ?= "minio/console:$(BUILD_VERSION ) -dev"
77MINIO_VERSION ?= "quay.io/minio/minio:latest"
88TARGET_BUCKET ?= "target"
9+ NODE_VERSION := $(shell cat .nvmrc)
910
1011default : console
1112
@@ -15,13 +16,13 @@ console:
1516 @ (GO111MODULE=on CGO_ENABLED=0 go build -trimpath --tags=kqueue,operator --ldflags " -s -w" -o console ./cmd/console)
1617
1718k8sdev :
18- @docker build -t $(TAG ) --build-arg build_version=$(BUILD_VERSION ) --build-arg build_time=' $(BUILD_TIME)' .
19+ @docker build -t $(TAG ) --build-arg build_version=$(BUILD_VERSION ) --build-arg build_time=' $(BUILD_TIME)' --build-arg NODE_VERSION= ' $(NODE_VERSION) ' .
1920 @kind load docker-image $(TAG )
2021 @echo " Done, now restart your console deployment"
2122
2223getdeps :
2324 @mkdir -p ${GOPATH} /bin
24- @echo " Installing golangci-lint" && curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(GOPATH ) /bin v1.45.2
25+ @echo " Installing golangci-lint" && curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(GOPATH ) /bin
2526
2627verifiers : getdeps fmt lint
2728
@@ -63,7 +64,8 @@ swagger-operator:
6364 @swagger generate server -A operator --main-package=operator --server-package=operatorapi --exclude-main -P models.Principal -f ./swagger-operator.yml -r NOTICE
6465
6566assets :
66- @ (cd portal-ui; yarn install --prefer-offline; make build-static; yarn prettier --write . --loglevel warn; cd ..)
67+ @ (if [ -f " ${NVM_DIR} /nvm.sh" ]; then \. " ${NVM_DIR} /nvm.sh" && nvm install && nvm use && npm install -g yarn ; fi && \
68+ cd portal-ui; yarn install --prefer-offline; make build-static; yarn prettier --write . --loglevel warn; cd ..)
6769
6870test-integration :
6971 @ (docker stop pgsqlcontainer || true)
@@ -261,7 +263,7 @@ clean:
261263 @rm -vf console
262264
263265docker :
264- @docker buildx build --output=type=docker --platform linux/amd64 -t $(TAG ) --build-arg build_version=$(BUILD_VERSION ) --build-arg build_time=' $(BUILD_TIME)' .
266+ @docker buildx build --output=type=docker --platform linux/amd64 -t $(TAG ) --build-arg build_version=$(BUILD_VERSION ) --build-arg build_time=' $(BUILD_TIME)' --build-arg NODE_VERSION= ' $(NODE_VERSION) ' .
265267
266268release : swagger-gen
267269 @echo " Generating Release: $( RELEASE) "
0 commit comments