Skip to content

Commit

Permalink
Merge pull request #16 from viceice/patch-1
Browse files Browse the repository at this point in the history
fix start service when already exists
  • Loading branch information
AJDurant authored Dec 1, 2023
2 parents 5046ef1 + 73dcb22 commit 215d2f0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion docker-engine.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<metadata>
<!-- == PACKAGE SPECIFIC SECTION == -->
<id>docker-engine</id>
<version>24.0.7</version>
<version>24.0.7.20231201</version>
<packageSourceUrl>https://github.com/AJDurant/choco-docker-engine</packageSourceUrl>
<owners>AJDurant</owners>
<!-- ============================== -->
Expand Down
14 changes: 7 additions & 7 deletions tools/chocolateyInstall.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -77,12 +77,12 @@ If (Test-OurOldDockerd) {
If (-not (Test-OurDockerd)) {
$scArgs = "create docker binpath= `"$dockerdPath --run-service`" start= auto displayname= `"$($env:ChocolateyPackageTitle)`""
Start-ChocolateyProcessAsAdmin -Statements "$scArgs" "C:\Windows\System32\sc.exe"
}

If (!$pp.StartService) {
Write-Host "$($env:ChocolateyPackageTitle) service created, start with: `sc start docker` "
}
Else {
Write-output "Starting docker service..."
Start-ChocolateyProcessAsAdmin -Statements "start docker" "C:\Windows\System32\sc.exe"
}
If (!$pp.StartService) {
Write-Host "$($env:ChocolateyPackageTitle) service created, start with: `sc start docker` "
}
Else {
Write-output "Starting docker service..."
Start-ChocolateyProcessAsAdmin -Statements "start docker" "C:\Windows\System32\sc.exe"
}

0 comments on commit 215d2f0

Please sign in to comment.