Skip to content

Instantly share code, notes, and snippets.

@santarinto
Created January 22, 2024 18:37
Show Gist options
  • Save santarinto/4d95842389ebac65297fb96c334b43dd to your computer and use it in GitHub Desktop.
Save santarinto/4d95842389ebac65297fb96c334b43dd to your computer and use it in GitHub Desktop.
$containerId = (docker ps -q --filter ancestor=mariadb)
if ($containerId -ne $null) {
# Остановка контейнера
docker stop $containerId
Write-Host "Docker container with ID $containerId has been stopped."
} else {
Write-Host "No running MariaDB Docker container found."
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment