Add make targets for Jenkins

these targets help hooking up things in Jenkins and enable us to
perform build & deploy tests for cloud images.

NOTE: use sudo -E to preserve the environment
This commit is contained in:
Alexander Todorov 2018-11-22 13:18:43 +02:00 committed by Alexander Todorov
parent c11bffc357
commit 366ae55abe
2 changed files with 16 additions and 6 deletions

View File

@ -47,7 +47,23 @@ test:
./tests/test_cli.sh
# need `losetup`, which needs Docker to be in privileged mode (--privileged)
# but even so fails in Travis CI
test_images:
sudo -E ./tests/test_cli.sh tests/cli/test_compose_ext4-filesystem.sh \
tests/cli/test_compose_partitioned-disk.sh
test_aws:
sudo -E ./tests/test_cli.sh tests/cli/test_build_and_deploy_aws.sh
test_azure:
sudo -E ./tests/test_cli.sh tests/cli/test_build_and_deploy_azure.sh
test_openstack:
sudo -E ./tests/test_cli.sh tests/cli/test_build_and_deploy_openstack.sh
test_vmware:
sudo -E ./tests/test_cli.sh tests/cli/test_build_and_deploy_vmware.sh
clean:
-rm -rf build src/pylorax/version.py

View File

@ -25,12 +25,6 @@ if [ -z "$*" ]; then
# invoke cli/ tests which can be executed without special preparation
./tests/cli/test_blueprints_sanity.sh
./tests/cli/test_compose_sanity.sh
# need `losetup`, which needs Docker to be in privileged mode (--privileged),
# which is available only for `docker run`, however we use `docker build`!
# And all of this may not even work on Travis CI so disabling execution for now!
# maybe we will figure out how to execute these two scripts on internal Jenkins instance
#./tests/cli/test_compose_ext4-filesystem.sh
#./tests/cli/test_compose_partitioned-disk.sh
else
# execute other cli tests which need more adjustments in the calling environment
# or can't be executed inside Travis CI