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

Disable tarball content type check in ingestion script #186

Merged
merged 4 commits into from
Apr 2, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions scripts/ingest-tarball.sh
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,6 @@ fi
# Get some information about the tarball
tar_file_basename=$(basename "${tar_file}")
version=$(echo "${tar_file_basename}" | cut -d- -f2)
contents_type_dir=$(echo "${tar_file_basename}" | cut -d- -f3)
bedroge marked this conversation as resolved.
Show resolved Hide resolved
tar_first_file=$(tar tf "${tar_file}" | head -n 1)
tar_top_level_dir=$(echo "${tar_first_file}" | cut -d/ -f1)
tar_contents_type_dir=$(tar tf "${tar_file}" | head -n 2 | tail -n 1 | cut -d/ -f2)
Expand All @@ -261,5 +260,4 @@ is_repo_owner || cvmfs_server="sudo cvmfs_server"
# Do some checks, and ingest the tarball
check_repo_vars
check_version
check_contents_type
bedroge marked this conversation as resolved.
Show resolved Hide resolved
ingest_${tar_contents_type_dir}_tarball
9 changes: 5 additions & 4 deletions scripts/test-ingest-tarball.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,11 @@ tarballs_success=(
# Test that should return an error
tarballs_fail=(
# Non-matching type dirs
"$tstdir/eessi-2000.01-compat-123456.tar.gz 2000.01 init"
"$tstdir/eessi-2000.01-init-123456.tar.gz 2000.01 initt"
"$tstdir/eessi-2000.01-scripts-123456.tar.gz 2000.01 scriptss"
"$tstdir/eessi-2000.01-software-123456.tar.gz 2000.01 soft"
# They have been disabled, as we removed the content type check in the ingestion script
# "$tstdir/eessi-2000.01-compat-123456.tar.gz 2000.01 init"
# "$tstdir/eessi-2000.01-init-123456.tar.gz 2000.01 initt"
# "$tstdir/eessi-2000.01-scripts-123456.tar.gz 2000.01 scriptss"
# "$tstdir/eessi-2000.01-software-123456.tar.gz 2000.01 soft"
# Non-matching versions
"$tstdir/eessi-2000.01-compat-123456.tar.gz 2000.12 compat"
"$tstdir/eessi-2000.01-init-123456.tar.gz 2000.12 init"
Expand Down
Loading