Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Implement deletion script for WSL2 port forwarding rules #20

Merged
merged 2 commits into from
Sep 11, 2023

Conversation

seanohair22
Copy link
Contributor

@seanohair22 seanohair22 commented Aug 23, 2023

PR Checklist

Author Mandatory (to be filled by PR Author/Submitter)

CODE MAINTAINABILITY

  • Commit Message meets guidelines as indicated in the URL*
  • Tests for the changes have been added (required for bug fixes / features). If not, state why not
    • Manual testing required
  • Added labels (these are git labels such as bug or enhancement)
  • For any API changes or service changes, updates to the documentation were made (Swagger APIs & GitHub Docs). If not, state why not
    • Adding as follow on PR
  • Every commit is a single defect fix and does not mix feature addition or changes*

What are the steps to test this PR contribution?

How does a reviewer know it works?

  • Run WSL_Port_Setup_Script.ps1 using Admin Powershell on OEM Device
  • Check status with the following:
    • netsh interface portproxy show all
    • Redirect output of Get-NetFirewallRule -Direction Inbound -Enabled True to a file then search for "Open SSH" (alternatively the rules should be at the bottom)
  • Run WSL_Port_Removal_Script.ps1 using Admin Powershell on OEM Device
  • Check status with the following:
    • netsh interface portproxy show all - The rules should be deleted
    • Redirect output of Get-NetFirewallRule -Direction Inbound -Enabled True to a file then search for "Open SSH" (alternatively the rules should be at the bottom) - The rules should be deleted

Are there any special instructions beyond standard workflow?

  • This requires Windows 10 and admin privileges to access Powershell as Admin

Maintainer Mandatory (to be filled by PR Reviewer/Approving Maintainer)

QUALITY CHECKS

  • Quality of code (At least one should be checked as applicable)*
    • Commit Message meets guidelines
    • Code copyright is correct
    • PR changes adhere to industry practices and standards as well as domain or language specific anti-patterns
    • Adopted domain specific coding standards (Go Coding Standards)
    • Code is adequately commented and documented
    • Confusing logic is explained in comments
    • Error and exception code paths implemented correctly
    • Tracing output are minimized and logic
  • Test coverage shows adequate coverage with required CI functional tests pass on all supported platforms*
  • Static code scan report shows zero critical issues*

Other information

Signed-off-by: Sean O'Hair <sean.ohair@intel.com>
@seanohair22 seanohair22 added the enhancement New feature or request label Aug 23, 2023
@seanohair22 seanohair22 requested a review from a team as a code owner August 23, 2023 19:11
@seanohair22 seanohair22 self-assigned this Aug 23, 2023
Copy link
Contributor

@ejlee3 ejlee3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - tested on windows in WSL - one thing to note is that I ran into a lot of permissions issues running the scripts and had to copy it from a WSL native folder to a different location (ie Downloads).

@seanohair22 seanohair22 merged commit 7bffaa4 into main Sep 11, 2023
1 of 2 checks passed
@seanohair22 seanohair22 deleted the wsl2_port_deletion_script branch September 11, 2023 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants