Compare commits

..

4 Commits

Author SHA1 Message Date
M. Mert Yıldıran
b59c48528d Upgrade Basenine version to v0.4.14 (#785)
Co-authored-by: Igor Gov <iggvrv@gmail.com>
2022-02-10 11:54:57 +03:00
leon-up9
24f1a07910 trim (#775)
Co-authored-by: Leon <>
Co-authored-by: lirazyehezkel <61656597+lirazyehezkel@users.noreply.github.com>
Co-authored-by: Igor Gov <iggvrv@gmail.com>
2022-02-10 10:42:48 +02:00
Igor Gov
d9e88169ae Fix: mizu check cmd when no mizu running (#787) 2022-02-10 09:08:49 +02:00
gadotroee
abf24a2230 Add help messages of make command and fix gsutil in tests (#783) 2022-02-09 14:26:57 +02:00
7 changed files with 31 additions and 15 deletions

View File

@@ -78,8 +78,8 @@ RUN go build -ldflags="-extldflags=-static -s -w \
-X 'github.com/up9inc/mizu/agent/pkg/version.Ver=${VER}'" -o mizuagent .
# Download Basenine executable, verify the sha1sum
ADD https://github.com/up9inc/basenine/releases/download/v0.4.13/basenine_linux_${GOARCH} ./basenine_linux_${GOARCH}
ADD https://github.com/up9inc/basenine/releases/download/v0.4.13/basenine_linux_${GOARCH}.sha256 ./basenine_linux_${GOARCH}.sha256
ADD https://github.com/up9inc/basenine/releases/download/v0.4.14/basenine_linux_${GOARCH} ./basenine_linux_${GOARCH}
ADD https://github.com/up9inc/basenine/releases/download/v0.4.14/basenine_linux_${GOARCH}.sha256 ./basenine_linux_${GOARCH}.sha256
RUN shasum -a 256 -c basenine_linux_${GOARCH}.sha256
RUN chmod +x ./basenine_linux_${GOARCH}
RUN mv ./basenine_linux_${GOARCH} ./basenine

View File

@@ -80,10 +80,10 @@ clean-agent: ## Clean agent.
clean-cli: ## Clean CLI.
@(cd cli; make clean ; echo "CLI cleanup done" )
clean-docker:
clean-docker: ## Run clen docker
@(echo "DOCKER cleanup - NOT IMPLEMENTED YET " )
test-lint:
test-lint: ## Run lint on all modules
cd agent && golangci-lint run
cd shared && golangci-lint run
cd tap && golangci-lint run
@@ -92,17 +92,17 @@ test-lint:
cd tap/api && golangci-lint run
cd tap/extensions/ && for D in */; do cd $$D && golangci-lint run && cd ..; done
test-cli:
test-cli: ## Run cli tests
@echo "running cli tests"; cd cli && $(MAKE) test
test-agent:
test-agent: ## Run agent tests
@echo "running agent tests"; cd agent && $(MAKE) test
test-shared:
test-shared: ## Run shared tests
@echo "running shared tests"; cd shared && $(MAKE) test
test-extensions:
test-extensions: ## Run extensions tests
@echo "running http tests"; cd tap/extensions/http && $(MAKE) test
acceptance-test:
acceptance-test: ## Run acceptance tests
@echo "running acceptance tests"; cd acceptanceTests && $(MAKE) test

View File

@@ -14,7 +14,7 @@ help: ## This help.
install:
go install mizu.go
build-debug:
build-debug: ## Build mizu CLI for debug
export GCLFAGS='-gcflags="all=-N -l"'
${MAKE} build

View File

@@ -74,9 +74,15 @@ func checkMizuMode(ctx context.Context, kubernetesProvider *kubernetes.Provider)
} else if exist {
logger.Log.Infof("%v mizu running with install command", fmt.Sprintf(uiUtils.Green, "√"))
return true, true
} else {
} else if exist, err = kubernetesProvider.DoesPodExist(ctx, config.Config.MizuResourcesNamespace, kubernetes.ApiServerPodName); err != nil {
logger.Log.Errorf("%v can't check mizu command, err: %v", fmt.Sprintf(uiUtils.Red, "✗"), err)
return false, false
} else if exist {
logger.Log.Infof("%v mizu running with tap command", fmt.Sprintf(uiUtils.Green, "√"))
return true, false
return true, true
} else {
logger.Log.Infof("%v mizu is not running", fmt.Sprintf(uiUtils.Red, "✗"))
return false, false
}
}

View File

@@ -9,8 +9,8 @@ test-update: test-pull-bin
test-pull-bin:
@mkdir -p bin
@[ "${skipbin}" ] && echo "Skipping downloading BINs" || gsutil -m cp gs://static.up9.io/mizu/test-pcap/bin/http/\*.bin bin
@[ "${skipbin}" ] && echo "Skipping downloading BINs" || gsutil -o 'GSUtil:parallel_process_count=5' -o 'GSUtil:parallel_thread_count=5' -m cp gs://static.up9.io/mizu/test-pcap/bin/http/\*.bin bin
test-pull-expect:
@mkdir -p expect
@[ "${skipexpect}" ] && echo "Skipping downloading expected JSONs" || gsutil -m cp -r gs://static.up9.io/mizu/test-pcap/expect/http/\* expect
@[ "${skipexpect}" ] && echo "Skipping downloading expected JSONs" || gsutil -o 'GSUtil:parallel_process_count=5' -o 'GSUtil:parallel_thread_count=5' -m cp -r gs://static.up9.io/mizu/test-pcap/expect/http/\* expect

View File

@@ -19,7 +19,10 @@ export const StatusBar = () => {
return <div className={'statusBar' + (expandedBar ? ' expandedStatusBar' : "")} onMouseOver={() => setExpandedBar(true)} onMouseLeave={() => setExpandedBar(false)}>
<div className="podsCount">
{tappingStatus.some(pod => !pod.isTapped) && <img src={warningIcon} alt="warning"/>}
{`Tapping ${amountOfUntappedPods > 0 ? amountOfTappedPods + " / " + amountOfPods : amountOfPods} ${pluralize('pod', amountOfPods)} in ${pluralize('namespace', uniqueNamespaces.length)} ${uniqueNamespaces.join(", ")}`}</div>
<span className='pods-count-text'>
{`Tapping ${amountOfUntappedPods > 0 ? amountOfTappedPods + " / " + amountOfPods : amountOfPods} ${pluralize('pod', amountOfPods)} in ${pluralize('namespace', uniqueNamespaces.length)} ${uniqueNamespaces.join(", ")}`}
</span>
</div>
{expandedBar && <div style={{marginTop: 20}}>
<table>
<thead>

View File

@@ -17,12 +17,19 @@
width: auto
max-height: 32px
overflow: hidden
max-width: clamp(150px,50%,600px)
.podsCount
display: flex
justify-content: center
font-weight: 600
.pods-count-text
width: 100%
max-width: 100%
white-space: nowrap
overflow: hidden
text-overflow: ellipsis
img
margin-right: 10px
height: 22px