Add File Extension to Windows IIS Container during image build

Let’s say: we need to add json file extension to the containerized IIS. Dockerfile: FROM {imageRegistry}/ COPY . /inetpub/wwwroot WORKDIR /inetpub/wwwroot RUN C:\windows\system32\inetsrv\appcmd.exe set config "Default Web Site" -section:system.webServer/security/requestFiltering /+"fileExtensions.[fileExtension='json',allowed='True']" ENV ASPNETCORE_URLS http://+:80 EXPOSE 80/tcp An error occurs during build docker image: Step 1/6 : FROM repo.q1lan.k8s:9999/ ---> a5bc996f06b3 Step 2/6 : COPY . /inetpub/wwwroot …

Proudly powered by WordPress