hardlinking should be post-sync to prod before file list

This commit is contained in:
Louis Abel 2022-07-15 16:05:14 -07:00
parent aec6a5d52d
commit 61451b1b37
Signed by untrusted user: label
GPG Key ID: B37E62D143879B36
5 changed files with 1639 additions and 6 deletions

File diff suppressed because it is too large Load Diff

View File

@ -22,6 +22,7 @@ PRODUCTION_ROOT="/mnt/repos-production"
# Override: Not Allowed
# relative to ${ENV}_ROOT
CATEGORY_STUB="mirror/pub/rocky"
SIG_CATEGORY_STUB="mirror/pub/sig"
# Override: Required
#RELEASE_DIR="${CATEGORY_STUB}/${REVISION}${APPEND_TO_DIR}"

View File

@ -24,7 +24,7 @@ if [ $ret_val -eq "0" ]; then
# Full file list update for rocky linux itself
cd "${PRODUCTION_ROOT}/${CATEGORY_STUB}/" || { echo "Failed to change directory"; exit 1; }
# Hardlink everything except xml files
hardlink -x '.*\.xml.*' "${REVISION}"
#hardlink -x '.*\.xml.*' "${REVISION}"
find . > fullfilelist
if [[ -f /usr/local/bin/create-filelist ]]; then
# We're already here, but Justin Case wanted this
@ -32,6 +32,7 @@ if [ $ret_val -eq "0" ]; then
/bin/cp fullfiletimelist-rocky fullfiletimelist-rocky-old
/usr/local/bin/create-filelist > fullfiletimelist-rocky
cp fullfiletimelist-rocky fullfiletimelist
cp fullfiletimelist-rocky fullfiletimelist-rocky-linux
fi
chown 10004:10005 fullfilelist fullfiletimelist-rocky fullfiletimelist
fi

View File

@ -28,10 +28,10 @@ if [ $ret_val -eq "0" ]; then
# cp fullfiletimelist-rocky fullfiletimelist
#fi
## Full file list update for rocky linux itself
#cd "${PRODUCTION_ROOT}/${CATEGORY_STUB}/" || { echo "Failed to change directory"; exit 1; }
cd "${PRODUCTION_ROOT}/${CATEGORY_STUB}/" || { echo "Failed to change directory"; exit 1; }
## Hardlink everything except xml files
#echo "Hard linking"
#hardlink -x '.*\.xml.*' "${REVISION}"
echo "Hard linking"
hardlink -x '.*\.xml.*' "${REVISION}"
#echo "Getting a full file list for the rocky dir"
#find . > fullfilelist
#if [[ -f /usr/local/bin/create-filelist ]]; then
@ -42,5 +42,6 @@ if [ $ret_val -eq "0" ]; then
# cp fullfiletimelist-rocky fullfiletimelist
#fi
#chown 10004:10005 fullfilelist fullfiletimelist-rocky fullfiletimelist
echo "Syncing to prod completed. Please run the file list script."
fi

View File

@ -43,9 +43,10 @@ if [ $ret_val -eq "0" ]; then
# cp fullfiletimelist-rocky fullfiletimelist
#fi
## Full file list update for rocky linux itself
#cd "${PRODUCTION_ROOT}/${CATEGORY_STUB}/" || { echo "Failed to change directory"; exit 1; }
cd "${PRODUCTION_ROOT}/${CATEGORY_STUB}/" || { echo "Failed to change directory"; exit 1; }
## Hardlink everything except xml files
#hardlink -x '.*\.xml.*' "${REVISION}"
echo "Hard linking"
hardlink -x '.*\.xml.*' "${REVISION}"
#find . > fullfilelist
#if [[ -f /usr/local/bin/create-filelist ]]; then
# # We're already here, but Justin Case wanted this
@ -55,5 +56,6 @@ if [ $ret_val -eq "0" ]; then
# cp fullfiletimelist-rocky fullfiletimelist
#fi
#chown 10004:10005 fullfilelist fullfiletimelist-rocky fullfiletimelist
echo "Syncing to prod completed. Please run the file list script."
fi