Is the spooler service supposed to work in new windows-insider image?

Brass Contributor

One of the things I tried is if the spooler service can be started and used in the new windows-insider image.

 

 

PS C:\windows\system32> net start spooler

net start spooler

System error 1058 has occurred.

 

The service cannot be started, either because it is disabled or because it has no enabled devices associated with it.

 

PS C:\> start-service spooler

start-service spooler

start-service : Service 'Print Spooler (spooler)' cannot be started due to the

following error: Cannot start service spooler on computer '.'.

At line:1 char:1

+ start-service spooler

+ ~~~~~~~~~~~~~~~~~~~~~

    + CategoryInfo          : OpenError: (System.ServiceProcess.ServiceController:ServiceController) [Start-Service], ServiceCommandException

    + FullyQualifiedErrorId : CouldNotStartService,Microsoft.PowerShell.Commands.StartServiceCommand

 

 

The services that the spooler service depends on seem to work, so I wonder what may be missing.

 

The first use-case for us would be a elegant test environment for our client software packaged as MSI. 

At the moment I have to spin up a VM and run unattend MSI installation and running some tests.

Using a Windows container would speed up our pipeline a lot as we always can have a clean Windows environment in seconds.

 

 

3 Replies

Just found out that the spooler service was disabled. After changing the startup type to automatic the spooler service seems to work.

 

$ cat Dockerfile

FROM mcr.microsoft.com/windows-insider

SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]

RUN Set-Service -Name spooler -StartupType Automatic

RUN Get-Printer

 

$ docker build --isolation hyperv --no-cache -t print .

Sending build context to Docker daemon  2.048kB

Step 1/4 : FROM mcr.microsoft.com/windows-insider

---> 09a59f60f394

Step 2/4 : SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]

---> Running in 59680f017c12

Removing intermediate container 59680f017c12

---> 94bce0226b5e

Step 3/4 : RUN Set-Service -Name spooler -StartupType Automatic

---> Running in 2dc61f761ef5

Removing intermediate container 2dc61f761ef5

---> c18e54ae08a3

Step 4/4 : RUN Get-Printer

---> Running in a843b0293503

 

Name                           ComputerName    Type         DriverName         

----                           ------------    ----         ----------         

Microsoft XPS Document Writer                  Local        Microsoft XPS Do...

Microsoft Print to PDF                         Local        Microsoft Print ...

Fax                                            Local        Microsoft Shared...

 

 

Removing intermediate container a843b0293503

---> 6347e0cdb9e9

Successfully built 6347e0cdb9e9

Successfully tagged print:latest

 


https://github.com/StefanScherer/dockerfiles-windows/tree/master/spooler

 

@Stefan Scherer can you manage to enable IIS feature on windows insider?

@MasterShana IIS is provided as a base image. You can find the Dockerfile here https://github.com/microsoft/iis-docker/blob/master/windowsservercore-insider/Dockerfile

This is for latest insider 19035, so it should work.