Skip to content

Commit

Permalink
init script: clean-up unused trusted_root.json files
Browse files Browse the repository at this point in the history
Signed-off-by: Firas Ghanmi <fghanmi@redhat.com>
  • Loading branch information
fghanmi committed Sep 11, 2024
1 parent 6e092b9 commit e9b7d4a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions rhtas/tuf-repo-init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,9 @@ else
echo "Key export location not specified, not exporting keys"
fi

# Remove ununused trusted_root.json files from ${OUTDIR}/targets
ls -t ${OUTDIR}/targets | grep trusted_root.json | tail -n +2 | xargs -I {} rm -- ${OUTDIR}/targets/{}

echo "Copying the TUF repository to final location ${TUF_REPO_PATH} ..."
# TODO: fix this based on changes in layout of tuftool output
cp -R "${OUTDIR}/." "${TUF_REPO_PATH}"
Expand Down

0 comments on commit e9b7d4a

Please sign in to comment.