Make the post import distribution checks less strict by OneBlue · Pull Request #13036 · microsoft/WSL

Summary of the Pull Request

This change allows distributions to be imported, even if they don't have a /bin/sh, as long as they have at least /etc.

PR Checklist

  • Closes: Link to issue WSL version updated to 2.5.7.0, caused docker Desktop to stop  #13006
  • Communication: I've discussed this with core contributors already. If work hasn't been agreed, this work might be rejected
  • Tests: Added/updated if needed and all pass
  • Localization: All end user facing strings can be localized
  • Dev docs: Added/updated if needed
  • Documentation updated: If checked, please file a pull request on our docs repo and link it here: #xxx

Detailed Description of the Pull Request / Additional comments

This change solves docker failing to register a distribution if it doesn't provide /bin/sh. See #13006 for details.

Validation Steps Performed

Added test coverage for this scenario