Skip to content

AWS Kubernetes tester, kubetest deployer implementation

License

Notifications You must be signed in to change notification settings

ik-cloud/aws-k8s-tester

Repository files navigation

WARNING: Pre-alpha. Do not use this in production. Only for testing.

awstester

Go Report Card Godoc Releases LICENSE

awstester eks

To install

go install -v ./cmd/awstester
awstester eks create cluster -h

To create an EKS testing cluster with ALB Ingress Controller

awstester eks create config --path ./awstester-eks.yaml

# change default configurations
vi ./awstester-eks.yaml
awstester eks create cluster --path ./awstester-eks.yaml

This will create an EKS cluster with ALB Ingress Controller (takes about 20 minutes).

Once cluster is created, check cluster state using AWS CLI:

aws eks describe-cluster \
  --name awstester-20180928-efeaantamazonco-Os0xhhKodH \
  --query cluster.status

"ACTIVE"

Cluser states are persisted on disk as well. EKS tester uses this file to track status.

cat ./awstester-eks.yaml

Once complete, get the DNS names from ./awstester-eks.yaml.

And curl the kube-system namespace's /metrics endpoint, to see if it works.

# for example
curl -L http://e5de0f6b-kubesystem-ingres-6aec-38954145.us-west-2.elb.amazonaws.com/metrics

Tear down the cluster (takes about 10 minutes):

awstester eks delete cluster --path ./awstester-eks.yaml

awstester eks e2e tests

To test locally:

# set "AWSTESTER_EKS_TAG" to avoid S3 bucket conflicts
# or just disable log uploads with "AWSTESTER_EKS_UPLOAD_TESTER_LOGS=false"
cd ${GOPATH}/src/github.com/aws/awstester
AWSTESTER_EKS_TEST_MODE=embedded \
  AWSTESTER_EKS_KUBERNETES_VERSION=1.10 \
  AWSTESTER_EKS_WAIT_BEFORE_DOWN=1m \
  AWSTESTER_EKS_DOWN=true \
  AWSTESTER_EKS_ENABLE_WORKER_NODE_HA=true \
  AWSTESTER_EKS_ENABLE_NODE_SSH=true \
  AWSTESTER_EKS_ENABLE_LOG_ACCESS=true \
  AWSTESTER_EKS_UPLOAD_TESTER_LOGS=false \
  AWSTESTER_EKS_UPLOAD_WORKER_NODE_LOGS=false \
  AWSTESTER_EKS_WORKER_NODE_INSTANCE_TYPE=m3.xlarge \
  AWSTESTER_EKS_WORKER_NODE_ASG_MIN=1 \
  AWSTESTER_EKS_WORKER_NODE_ASG_MAX=1 \
  AWSTESTER_EKS_ALB_ENABLE=true \
  AWSTESTER_EKS_ALB_UPLOAD_TESTER_LOGS=false \
  AWSTESTER_EKS_ALB_TARGET_TYPE=ip \
  AWSTESTER_EKS_ALB_TEST_MODE=nginx \
  AWSTESTER_EKS_ALB_TEST_SCALABILITY=true \
  AWSTESTER_EKS_ALB_TEST_METRICS=true \
  AWSTESTER_EKS_ALB_TEST_SERVER_REPLICAS=3 \
  AWSTESTER_EKS_ALB_TEST_SERVER_ROUTES=1 \
  AWSTESTER_EKS_ALB_TEST_CLIENTS=20 \
  AWSTESTER_EKS_ALB_TEST_CLIENT_REQUESTS=200 \
  AWSTESTER_EKS_ALB_TEST_RESPONSE_SIZE=20000 \
  AWSTESTER_EKS_ALB_TEST_CLIENT_ERROR_THRESHOLD=50 \
  AWSTESTER_EKS_ALB_TEST_EXPECT_QPS=100 \
  AWSTESTER_EKS_ALB_INGRESS_CONTROLLER_IMAGE=quay.io/coreos/alb-ingress-controller:1.0-beta.7 \
  ./tests/ginkgo.sh

About

AWS Kubernetes tester, kubetest deployer implementation

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 98.2%
  • Shell 1.3%
  • Other 0.5%