Implement GitHub Action to automate patches and documentation #310
Implement GitHub Action to automate patches and documentation #310Pequod55 wants to merge 10 commits intogoogle:masterfrom
Conversation
- Introduced a GitHub Actions workflow (`modify_patches.yml`) to automate the modification of patch files and documentation upon pull requests to the master branch. - Created `modify_patchlist.md` to serve as a user guide for adding new patches, detailing the steps and structure required in `modify_patchlist.yaml`. - Added `modify_patchlist.yaml` as a centralized manifest for Oracle software and patch information, including sections for various software types and patches, along with example entries.
…hes_insert_patch function
…being commented out before docs can be applied
… add requirements file for dependencies
This change introduces a new workflow to streamline the process of adding, updating, and documenting patches. The solution is summarized as: - A single input file, modify_patchlist.yaml, is used to define new software and patches. - A GitHub Action is triggered on Pull Requests, which automatically executes the update logic. - A new Python script (.github/workflows/modify_patches.py) parses the input file, removes duplicate/older patch versions, and updates the primary Ansible configuration (roles/common/defaults/main.yml). - A second Python script (.github/workflows/modify_documentation.py) updates the software download tables in the user guide (docs/user-guide.md). - The automation is idempotent; it comments out processed entries in modify_patchlist.yaml to prevent re-runs. - A Bash script (.github/workflows/commit_patches.bash) commits all automated changes back to the user's branch. - Documentation is updated with a user and technical guide for the new process.
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: Pequod55 The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
|
Hi @Pequod55. Thanks for your PR. I'm waiting for a google member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
Is this a dupe of #343 ? If so, should we close this one? |
|
@mfielding Apologies I forgot to close this PR, #343 is the simplified version with unit tests! |
Solution Overview:
This change introduces a new workflow to streamline the process of adding, updating, and documenting patches. The solution is summarized as:
Test Commands:
The primary test is to follow the new user workflow. These steps simulate a user adding a new RDBMS patch.
Test Prep:
rdbms_patches:
- { category: "RU", base: "21.3.0.0.0", release: "21.99.0.0.0", patchnum: "39999999", patchfile: "p39999999_210000_Linux-x86-64.zip", patch_subdir: "/", prereq_check: false, method: "opatch apply", ocm: false, upgrade: false, md5sum: "a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4" }In the same file, add an override for the documentation under documentation_overrides:
Test 1: Run the automation scripts locally
Simulate the GitHub Action by running the scripts in order to validate their logic.
Test 2: Run the full Git workflow (End-to-End Test)
This test validates the complete, automated process as it would run in a PR.
git add modify_patchlist.yaml git commit -m "feat: Add test RDBMS patch 21.99"Expected Results:
For Test 1 (Local Run):
For Test 2 (PR Workflow):