User Manual: Remove old files for when deploying #7

Merged
Bart van der Braak merged 4 commits from Blendify/blender-devops:manual-doc-rsync-delete into main 2024-10-04 10:56:45 +02:00
Contributor

This ensures deleted files do not remain on the server and can still be indexed by search engines.

Similar to 832a15101c

Fixes blender/blender-manual#104500

This ensures deleted files do not remain on the server and can still be indexed by search engines. Similar to 832a15101c80d91359dc8c98d425342b55f576d2 Fixes https://projects.blender.org/blender/blender-manual/issues/104500
Aaron Carlisle added 1 commit 2024-09-10 01:54:35 +02:00
This ensures deleted files do not remain on the server and can still be indexed by search engines.

Similar to 832a15101c
Aaron Carlisle requested review from Brecht Van Lommel 2024-09-10 01:54:45 +02:00
Aaron Carlisle requested review from Bart van der Braak 2024-09-10 01:54:46 +02:00
Sergey Sharybin removed review request for Brecht Van Lommel 2024-09-11 11:25:45 +02:00
Sergey Sharybin reviewed 2024-09-11 11:28:38 +02:00
@ -217,3 +217,3 @@
source_path = f"{builder.build_path}/{doc_format}/{locale}/"
dest_path = f"{connect_id}:{version_remote_path}/"
worker.utils.rsync(source_path, dest_path, exclude_paths=[".doctrees"])
# Exclude zip files so `--delete` does not delete existing archives

The comment can become more descriptive. It is possibly to deduct that detete=True and --exclude=*.zip will preserve archives. But why is it needed? What the existing archives referred from the comment exactly are?

The comment can become more descriptive. It is possibly to deduct that `detete=True` and `--exclude=*.zip` will preserve archives. But why is it needed? What the existing archives referred from the comment exactly are?

There are html and epub zip files in the same folder, for downloading the manual. The epub zip in particular is uploaded by a builder that runs in parallel with this one.

There are html and epub zip files in the same folder, for downloading the manual. The epub zip in particular is uploaded by a builder that runs in parallel with this one.
Blendify marked this conversation as resolved

Brecht is on sabbatical. I'm taking care of things he was responsible before.
The change is probably fine, but it would be very good to have a bit more explanation. See the inlined comment.

Brecht is on sabbatical. I'm taking care of things he was responsible before. The change is probably fine, but it would be very good to have a bit more explanation. See the inlined comment.
Brecht Van Lommel reviewed 2024-09-12 01:06:26 +02:00
@ -218,2 +218,3 @@
dest_path = f"{connect_id}:{version_remote_path}/"
worker.utils.rsync(source_path, dest_path, exclude_paths=[".doctrees"])
# Exclude zip files so `--delete` does not delete existing archives
worker.utils.rsync(source_path, dest_path, exclude_paths=[".doctrees", ".*zip"], delete=True, delete_path_check=docs_remote_path)

I have not tested, but the pattern looks wrong and the folder could be more specific:
.*.zip -> *.zip
docs_remote_path -> version_remote_path

I have not tested, but the pattern looks wrong and the folder could be more specific: `.*.zip` -> `*.zip` `docs_remote_path` -> `version_remote_path`
Blendify marked this conversation as resolved
Aaron Carlisle added 2 commits 2024-09-27 06:28:30 +02:00
Aaron Carlisle requested review from Sergey Sharybin 2024-09-27 06:30:48 +02:00
Aaron Carlisle added 1 commit 2024-09-27 06:32:46 +02:00
Author
Contributor

Should be good to go now.

Should be good to go now.
Author
Contributor

@brecht @Sergey can this get reviewed and merged?

@brecht @Sergey can this get reviewed and merged?

@Blendify Brecht is on sabbatical. There is also some internal stuff which keeps Bart busy. However, with 4.3 tracks getting under control now we should be able to tackle this PR.

@Blendify Brecht is on sabbatical. There is also some internal stuff which keeps Bart busy. However, with 4.3 tracks getting under control now we should be able to tackle this PR.
Bart van der Braak approved these changes 2024-10-04 10:24:28 +02:00
Sergey Sharybin approved these changes 2024-10-04 10:26:50 +02:00
Sergey Sharybin left a comment
Owner

The code looks correct now. Bart will help with deployment to UATEST and PROD, Iv've synced up with him in the blender-coders.

The code looks correct now. Bart will help with deployment to UATEST and PROD, Iv've synced up with him in the blender-coders.
Bart van der Braak merged commit e9592d14ad into main 2024-10-04 10:56:45 +02:00
Bart van der Braak deleted branch manual-doc-rsync-delete 2024-10-04 10:56:46 +02:00
Sign in to join this conversation.
No Label
No Milestone
No Assignees
4 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: infrastructure/blender-devops#7
No description provided.