Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Start using e2e test images from gcr.io #5807

Merged
merged 3 commits into from Jun 27, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion build/dev-env.sh
Expand Up @@ -61,7 +61,7 @@ echo "[dev-env] building image"
make build image
docker tag "${REGISTRY}/nginx-ingress-controller:${TAG}" "${DEV_IMAGE}"

export K8S_VERSION=${K8S_VERSION:-v1.18.0@sha256:0e20578828edd939d25eb98496a685c76c98d54084932f76069f886ec315d694}
export K8S_VERSION=${K8S_VERSION:-v1.18.2@sha256:7b27a6d0f2517ff88ba444025beae41491b016bc6af573ba467b70c5e8e0d85f}

KIND_CLUSTER_NAME="ingress-nginx-dev"

Expand Down
2 changes: 1 addition & 1 deletion build/run-in-docker.sh
Expand Up @@ -34,7 +34,7 @@ function cleanup {
}
trap cleanup EXIT

E2E_IMAGE=${E2E_IMAGE:-quay.io/kubernetes-ingress-controller/e2e:v05312020-d250b97b4}
E2E_IMAGE=${E2E_IMAGE:-gcr.io/k8s-staging-ingress-nginx/e2e-test-runner:v20200627-ingress-nginx-2.9.0-9-ga003eabd5}

DOCKER_OPTS=${DOCKER_OPTS:-}

Expand Down
2 changes: 1 addition & 1 deletion test/e2e-image/Dockerfile
@@ -1,4 +1,4 @@
FROM quay.io/kubernetes-ingress-controller/e2e:v05312020-d250b97b4 AS BASE
FROM gcr.io/k8s-staging-ingress-nginx/e2e-test-runner:v20200627-ingress-nginx-2.9.0-9-ga003eabd5 AS BASE

FROM alpine:3.12

Expand Down
4 changes: 2 additions & 2 deletions test/e2e/framework/deployment.go
Expand Up @@ -52,7 +52,7 @@ func (f *Framework) NewEchoDeploymentWithReplicas(replicas int) {
// replicas is configurable and
// name is configurable
func (f *Framework) NewEchoDeploymentWithNameAndReplicas(name string, replicas int) {
deployment := newDeployment(name, f.Namespace, "ingress-controller/echo:1.0.0-dev", 80, int32(replicas),
deployment := newDeployment(name, f.Namespace, "gcr.io/k8s-staging-ingress-nginx/e2e-test-echo:v20200627-ingress-nginx-2.9.0-11-g35e992fe0", 80, int32(replicas),
nil,
[]corev1.VolumeMount{},
[]corev1.Volume{},
Expand Down Expand Up @@ -343,7 +343,7 @@ func newDeployment(name, namespace, image string, port int32, replicas int32, co

// NewHttpbinDeployment creates a new single replica deployment of the httpbin image in a particular namespace.
func (f *Framework) NewHttpbinDeployment() {
f.NewDeployment(HTTPBinService, "ingress-controller/httpbin:1.0.0-dev", 80, 1)
f.NewDeployment(HTTPBinService, "gcr.io/k8s-staging-ingress-nginx/e2e-test-httpbin:v20200627-ingress-nginx-2.9.0-12-gfc91afac8", 80, 1)
}

// NewDeployment creates a new deployment in a particular namespace.
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/fastcgi_helloserver.go
Expand Up @@ -58,7 +58,7 @@ func (f *Framework) NewNewFastCGIHelloServerDeploymentWithReplicas(replicas int3
Containers: []corev1.Container{
{
Name: "fastcgi-helloserver",
Image: "ingress-controller/fastcgi-helloserver:1.0.0-dev",
Image: "gcr.io/k8s-staging-ingress-nginx/e2e-test-fastcgi-helloserver:v20200627-ingress-nginx-2.9.0-8-g1fcf4444c",
Env: []corev1.EnvVar{},
Ports: []corev1.ContainerPort{
{
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/util.go
Expand Up @@ -38,7 +38,7 @@ const (
Poll = 2 * time.Second

// DefaultTimeout time to wait for operations to complete
DefaultTimeout = 90 * time.Second
DefaultTimeout = 180 * time.Second
)

func nowStamp() string {
Expand Down
20 changes: 6 additions & 14 deletions test/e2e/run.sh
Expand Up @@ -53,7 +53,7 @@ export TAG=1.0.0-dev
export ARCH=${ARCH:-amd64}
export REGISTRY=ingress-controller

export K8S_VERSION=${K8S_VERSION:-v1.18.0@sha256:0e20578828edd939d25eb98496a685c76c98d54084932f76069f886ec315d694}
export K8S_VERSION=${K8S_VERSION:-v1.18.2@sha256:7b27a6d0f2517ff88ba444025beae41491b016bc6af573ba467b70c5e8e0d85f}

export DOCKER_CLI_EXPERIMENTAL=enabled

Expand All @@ -76,27 +76,19 @@ echo "[dev-env] building image"

make -C ${DIR}/../../ clean-image build image
make -C ${DIR}/../e2e-image image
make -C ${DIR}/../../images/fastcgi-helloserver/ build image
make -C ${DIR}/../../images/httpbin/ image
make -C ${DIR}/../../images/echo/ image
make -C ${DIR}/../../images/cfssl/ image

# Preload images used in e2e tests
docker pull moul/grpcbin
docker pull quay.io/kubernetes-ingress-controller/nginx:e3c49c52f4b74fe47ad65d6f3266a02e8b6b622f
#make -C ${DIR}/../../images/fastcgi-helloserver/ build image
#make -C ${DIR}/../../images/echo/ image

# Preload images used in e2e tests
KIND_WORKERS=$(kind get nodes --name="${KIND_CLUSTER_NAME}" | grep worker | awk '{printf (NR>1?",":"") $1}')

echo "[dev-env] copying docker images to cluster..."

kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} nginx-ingress-controller:e2e
kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} ${REGISTRY}/nginx-ingress-controller:${TAG}
kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} ${REGISTRY}/fastcgi-helloserver:${TAG}
kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} ${REGISTRY}/httpbin:${TAG}
kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} ${REGISTRY}/echo:${TAG}
kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} quay.io/kubernetes-ingress-controller/nginx:e3c49c52f4b74fe47ad65d6f3266a02e8b6b622f
kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} moul/grpcbin
kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} ${REGISTRY}/cfssl:${TAG}
#kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} ${REGISTRY}/fastcgi-helloserver:${TAG}
#kind load docker-image --name="${KIND_CLUSTER_NAME}" --nodes=${KIND_WORKERS} ${REGISTRY}/echo:${TAG}

echo "[dev-env] running e2e tests..."
make -C ${DIR}/../../ e2e-test
2 changes: 1 addition & 1 deletion test/e2e/settings/ocsp/ocsp.go
Expand Up @@ -302,7 +302,7 @@ func ocspserveDeployment(namespace string) (*appsv1.Deployment, *corev1.Service)
Containers: []corev1.Container{
{
Name: name,
Image: "ingress-controller/cfssl:1.0.0-dev",
Image: "gcr.io/k8s-staging-ingress-nginx/e2e-test-cfssl:v20200627-ingress-nginx-2.9.0-8-g1fcf4444c",
Command: []string{
"/bin/bash",
"-c",
Expand Down
3 changes: 1 addition & 2 deletions test/e2e/wait-for-nginx.sh
Expand Up @@ -51,10 +51,9 @@ if [[ ! -z "$NAMESPACE_OVERLAY" && -d "$DIR/namespace-overlays/$NAMESPACE_OVERLA
echo "Namespace overlay $NAMESPACE_OVERLAY is being used for namespace $NAMESPACE"
helm install nginx-ingress ${DIR}/charts/ingress-nginx \
--namespace=$NAMESPACE \
--wait \
--values "$DIR/namespace-overlays/$NAMESPACE_OVERLAY/values.yaml"
else
cat << EOF | helm install nginx-ingress ${DIR}/charts/ingress-nginx --namespace=$NAMESPACE --wait --values -
cat << EOF | helm install nginx-ingress ${DIR}/charts/ingress-nginx --namespace=$NAMESPACE --values -
# TODO: remove the need to use fullnameOverride
fullnameOverride: nginx-ingress
controller:
Expand Down