From a3686a60a9a2e0ba8c8b830761fdf0474f2879fe Mon Sep 17 00:00:00 2001 From: "Eric D. Helms" Date: Sun, 27 Aug 2023 15:13:32 -0400 Subject: [PATCH] rsync to project directory and cleanup cache after --- puppet/modules/web/templates/deploy-stagingyum.sh.erb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/puppet/modules/web/templates/deploy-stagingyum.sh.erb b/puppet/modules/web/templates/deploy-stagingyum.sh.erb index 996e3e790..04430c792 100644 --- a/puppet/modules/web/templates/deploy-stagingyum.sh.erb +++ b/puppet/modules/web/templates/deploy-stagingyum.sh.erb @@ -8,4 +8,7 @@ $SSH_ORIGINAL_COMMAND # Publish the site - stderr/out redirect is required to stop the noninteractive shell from hanging - rsync -rvx --delete-after <%= @home %>/rsync_cache/$PROJECT/$RELEASE <%= @yum_directory %>/ 2>&1 >/dev/null ; + rsync -rvx --delete-after <%= @home %>/rsync_cache/$PROJECT/$RELEASE <%= @yum_directory %>/$PROJECT/ 2>&1 >/dev/null ; + + # Cleanup - no need to keep the RPMs + find <%= @home %>/rsync_cache/$PROJECT/$RELEASE -iname '*.rpm' -delete || true