Autostart docker containers in Windows?

Notice: Page may contain affiliate links for which we may earn a small commission through services like Amazon Affiliates or Skimlinks.

IamSpartacus

Well-Known Member
Mar 14, 2016
2,516
650
113
I'm having trouble finding any good documentation on how to get docker containers to autostart with Windows. Can someone point me towards how to do this?
 

marcoi

Well-Known Member
Apr 6, 2013
1,533
289
83
Gotha Florida
i would probably create a batch file to start the dockers, then put it into windows scheduler with task to run whenever the system boots.
There might be a better way to do this but the above first thing that came to me.
 

IamSpartacus

Well-Known Member
Mar 14, 2016
2,516
650
113
i would probably create a batch file to start the dockers, then put it into windows scheduler with task to run whenever the system boots.
There might be a better way to do this but the above first thing that came to me.
The problem is that requires login. I want to get a docker and specific containers to auto start with Windows without user login.
 

IamSpartacus

Well-Known Member
Mar 14, 2016
2,516
650
113
Alright, I accomplished this by creating a scheduled task that calls "C:\Program Files\Docker\Docker\Docker for Windows.exe". My container is set to --restart always so it starts with the docker service.
 
Last edited:
  • Like
Reactions: K D