-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Drop Dockerfile in test images #1792
Changes from all commits
886b48e
6676a24
89397f4
179d7ba
d7c88d1
17517ff
5835163
d3ff17c
763bdd4
266c7ec
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -109,6 +109,13 @@ function dump_extra_cluster_state() { | |
kubectl logs $(get_app_pod controller knative-serving) | ||
} | ||
|
||
function publish_test_images() { | ||
image_dirs="$(find ${REPO_ROOT_DIR}/test/test_images -mindepth 1 -maxdepth 1 -type d)" | ||
for image_dir in ${image_dirs}; do | ||
ko publish -P "github.com/knative/serving/test/test_images/$(basename ${image_dir})" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It is notable that this will not work with DockerHub (and possible other registries), which is why I'd changed the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Shall I fix this separately? |
||
done | ||
} | ||
|
||
# Script entry point. | ||
|
||
initialize $@ | ||
|
@@ -121,6 +128,8 @@ header "Building and starting Knative Serving" | |
export KO_DOCKER_REPO=${DOCKER_REPO_OVERRIDE} | ||
create_everything | ||
|
||
publish_test_images | ||
|
||
# Handle test failures ourselves, so we can dump useful info. | ||
set +o errexit | ||
set +o pipefail | ||
|
@@ -138,7 +147,6 @@ options="" | |
report_go_test \ | ||
-v -tags=e2e -count=1 -timeout=20m \ | ||
./test/conformance ./test/e2e \ | ||
${options} \ | ||
-dockerrepo gcr.io/knative-tests/test-images/knative-serving || fail_test | ||
${options} || fail_test | ||
|
||
success |
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,15 +16,11 @@ | |
|
||
set -o errexit | ||
|
||
: ${1:?"Pass the directories with the test images as arguments"} | ||
: ${DOCKER_REPO_OVERRIDE:?"You must set 'DOCKER_REPO_OVERRIDE', see DEVELOPMENT.md"} | ||
|
||
DOCKER_FILES="$(find $@ -name Dockerfile)" | ||
: ${DOCKER_FILES:?"No subdirectories with Dockerfile files found in $@"} | ||
export KO_DOCKER_REPO=${DOCKER_REPO_OVERRIDE} | ||
IMAGE_DIRS="$(find $(dirname $0)/test_images -mindepth 1 -maxdepth 1 -type d)" | ||
|
||
for docker_file in ${DOCKER_FILES}; do | ||
image_dir="$(dirname ${docker_file})" | ||
versioned_name="${DOCKER_REPO_OVERRIDE}/knative-serving/$(basename ${image_dir})" | ||
docker build "${image_dir}" -f "${docker_file}" -t "${versioned_name}" | ||
docker push "${versioned_name}" | ||
for image_dir in ${IMAGE_DIRS}; do | ||
ko publish -P "github.com/knative/serving/test/test_images/$(basename ${image_dir})" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. cc @imjasonh 🦜 thanks for |
||
done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please note here that this is now only required when running the tests locally.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done