Why can't IIS read Web.config within a folder created by Bash on Windows?
Credit to therealkenc at github.com/Microsoft/WSL/issues/3596 for pointing me in the right direction. The issue is related to Per-directory case sensitivity and WSL.
Query a directory's case sensitive flag:
fsutil.exe file queryCaseSensitiveInfo <path>
Set a directory's case sensitive flag:
fsutil.exe file setCaseSensitiveInfo <path> enable
fsutil.exe file setCaseSensitiveInfo <path> disable
After disabling the case sensitive flag on the WebBash
directory, IIS read Web.config just fine. This led me to consider the possibility that IIS was looking for lower-case web.config
. I re-enabled case sensitivity on directory WebBash
and copied Web.config
to web.config
(yep, Windows Explorer let me keep both in the same folder). IIS read web.config
just fine!