actions: check for packaging before clone

If already exit do not clone it, but fetch.

Fetch will keep repository is up-to-date before checkout.

Fixes: #911

Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
This commit is contained in:
Jose Carlos Venegas Munoz 2020-01-15 15:24:59 +00:00
parent 626536e7bd
commit 32f2ff181c

View File

@ -103,8 +103,9 @@ function test_kata() {
# 2. From kata-containers: when creating a release, the appropriate packaging repository is
# not yet part of the workspace, and we will need to clone
if [[ ! -d ./kata-deploy ]]; then
git clone https://github.com/kata-containers/packaging packaging
[[ -d packaging ]] || git clone https://github.com/kata-containers/packaging packaging
cd packaging
git fetch
git checkout $PKG_SHA
fi