mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-05-17 18:25:26 +00:00
code review
This commit is contained in:
@@ -56,6 +56,17 @@ function run_tshirt_benchmark {
|
|||||||
run_fn $loop "T-shirt Example Container Function" "example_tshirt/containerfn"
|
run_fn $loop "T-shirt Example Container Function" "example_tshirt/containerfn"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if [ "$1" != "--doIt" ]; then
|
||||||
|
echo "Usage: $0 --doIt"
|
||||||
|
echo " "
|
||||||
|
echo "This script measures performance of kustomize containerized"
|
||||||
|
echo "functions (KRM config functions) implementation."
|
||||||
|
echo "It does so by running functions in local executable mode and"
|
||||||
|
echo "in container mode for 10, 100 and 1000 times. The time"
|
||||||
|
echo "used in these 2 modes are recorded."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
loops=(10 100 1000)
|
loops=(10 100 1000)
|
||||||
|
|
||||||
build_exec
|
build_exec
|
||||||
|
|||||||
@@ -5,4 +5,5 @@ BUILD_HOME=/usr/local/build
|
|||||||
|
|
||||||
docker build -t $IMAGE_LABEL .
|
docker build -t $IMAGE_LABEL .
|
||||||
|
|
||||||
docker run --rm -v $(pwd):/out $IMAGE_LABEL cp -r $BUILD_HOME/functions/examples/injection-tshirt-sizes/image/tshirt /out
|
docker run --rm -v $(pwd):/out $IMAGE_LABEL \
|
||||||
|
cp -r $BUILD_HOME/functions/examples/injection-tshirt-sizes/image/tshirt /out
|
||||||
|
|||||||
@@ -5,4 +5,5 @@ BUILD_HOME=/usr/local/build
|
|||||||
|
|
||||||
docker build -t $IMAGE_LABEL .
|
docker build -t $IMAGE_LABEL .
|
||||||
|
|
||||||
docker run --rm -v $(pwd):/out $IMAGE_LABEL cp -r $BUILD_HOME/ts/hello-world/dist $BUILD_HOME/ts/hello-world/node_modules /out
|
docker run --rm -v $(pwd):/out $IMAGE_LABEL \
|
||||||
|
cp -r $BUILD_HOME/ts/hello-world/dist $BUILD_HOME/ts/hello-world/node_modules /out
|
||||||
|
|||||||
@@ -1,9 +1,9 @@
|
|||||||
# Benchmark for KRM functions in Kustomize
|
# Benchmark for KRM functions in Kustomize
|
||||||
|
|
||||||
## Pre-request
|
## Pre-prerequisites
|
||||||
|
|
||||||
- You have to use Kustomize version with KRM function supported.
|
- [kustomize v3.7.0 or higher](https://kubernetes-sigs.github.io/kustomize/installation) (support for KRM Config Functions).
|
||||||
- You need to have Docker running on your machine.
|
- [docker](https://github.com/kubernetes-sigs/kustomize/pull/docker.com)
|
||||||
|
|
||||||
## How to run
|
## How to run
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user