-
Notifications
You must be signed in to change notification settings - Fork 0
Fix fatal error due to missing database user #5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
Hey @mloskot, could you please test the latest tag of the Windows container on your machine? |
|
Windows container seems to run correctly inside a Microsoft-hosted agent using windows-2022 VM image, as seen here. |
|
Hey @mloskot, I was able to replicate the initial error after setting up a Windows 11 VM; I managed to identify a way to avoid triggering the error Also, could you please specify the steps needed to make the volume work with the Windows container? It seems you know more than me about a working solution ...
Now that I have a Windows 11 VM, I could try refining my approach for building Windows container image using your tips. |
|
Hi @satrapu, I checked the latest image (
Here is PowerShell script which mounts two directories as volumes on the container as $image = "satrapu/postgresql"
$tag = "latest-windows"
$container = ('{0}-{1}' -f $image.Replace('/', '-'), $tag)
$volumeTest = $PSScriptRoot
$volumeData = Join-Path -Path $PSScriptRoot -ChildPath 'data'
if (-not (Test-Path -Path $volumeData -PathType Container)) {
New-Item -Path $volumeData -ItemType Directory -ErrorAction Stop
}
$dockerArgs = @('run', '-it', '--name' , $container)
$dockerArgs += '--env'
$dockerArgs += 'PGDATA=C:\data'
$dockerArgs += '--volume'
$dockerArgs += ('{0}:C:\data' -f $volumeData)
$dockerArgs += '--volume'
$dockerArgs += ('{0}:C:\test' -f $volumeTest)
$dockerArgs += ('{0}:{1}' -f $image, $tag)
Write-Host "docker $dockerArgs"
docker $dockerArgsbut the entrypoint does not seem to use the |
|
@mloskot, due to personal reasons I need to suspend working on this issue, but I will continue investigating it after 2 weeks or so. |
|
No worries @satrapu take your time |



Fix for pg_isready: FATAL: database "ContainerUser" does not exist (#4)