diff --git a/bin/blackbox_postdeploy b/bin/blackbox_postdeploy index 554236c..a095c90 100755 --- a/bin/blackbox_postdeploy +++ b/bin/blackbox_postdeploy @@ -30,8 +30,9 @@ echo '========== Decrypting new/changed files: START' while IFS= read <&99 -r unencrypted_file; do encrypted_file=$(get_encrypted_filename "$unencrypted_file") decrypt_file_overwrite "$encrypted_file" "$unencrypted_file" - chmod g+r "$unencrypted_file" + chmod --reference "$encrypted_file" "$unencrypted_file" if [[ ! -z "$FILE_GROUP" ]]; then + chmod g+r "$unencrypted_file" chgrp "$FILE_GROUP" "$unencrypted_file" fi done 99<"$BB_FILES"