Did anyone manage to run FBCMD.exe in a Windows Docker Container?

Hello everyone,

I am trying to get Finalbuilder (FBCMD.exe) run inside a Windows Docker Container. On my server there is a Jenkins master that uses the Docker Containers as slaves. As a Build Step I want to start a FB8 Project inside the Container via FBCMD.exe (I know about the licenses I need for the virtualization, got a site license).

I installed FB8 with a /VERYSILENT Install inside the container. The Docker Container has .net framework > 4.5 and Powershell Version 5.xx. ans the license key is located in the correct path. “C:\Program Data…”

But everytime I try to run the FBCMD.exe inside the container it does absolutely nothing. The same command works on my desktop pc.

Anyone knows how to fix this? Or got it working?

LG
MrChuky

Hi MrChuky,

Can you send on your Dockerfile with the steps to build the docker image? This will help us to reproduce the issue.

Hi Sparky,

I did not use a Dockerfile. The way I created the container is the following:

  1. Used the “mcr.microsoft.com/windows/servercore” image and started a container
  2. Gave the container a Volume to easily copy files from my host (Win Server 2016) to the container.
  3. Checked Powershell and .net Framework Version
  4. Copied the FB8 installer to the container
  5. Installed it via “.\FB800… /VERYSILENT” and checked if the files are existent in “…Program Files (x86)”
  6. Moved the license key from my host to “C:\Program Data\VSoft…”
  7. Stopped the container and created a new image using the “docker commit” command
  8. Started a new container with the recently created image and tried to start the FBCMD.exe

and thats the point where I got stuck. Parallel to the steps mentioned above I installed Java and copied the agent.jar into the container. They are working correctly in the newly created image.

MrChuky

Thanks for the additional information. We set up a similar docker container today and had the same result when running fbcmd.exe - no output and no event log entry. Something is missing but we’re not sure what. We’ll investigate further on Monday.

1 Like

Thanks for your investigation. Looking forward to a reply!
Have a nice weekend.

Further investigation shows us that fbcmd is failing to start with $C0000135 (“the program can’t start because %hs is missing from your computer. Try reinstalling the program to fix this problem.”) - not very helpful from windows at all (no more details, nothing in the event log).

I set up a server core vm to test with, and made some progress, in that it shows a messagebox with the name of the missing dll - copying opengl32.dll, glu32.dll and oledlg.dll from c:\windows\SysWOW64\ on my up to date W10 machine allows fbcmd to run.

Unfortunately, that doesn’t seem to work in the docker container, using this dockerfile

# escape=`

# Use the latest Windows Server Core image with .NET Framework 4.8.
FROM mcr.microsoft.com/dotnet/framework/sdk:4.8-windowsservercore-ltsc2019

# Restore the default Windows shell for correct batch processing.
SHELL ["cmd", "/S", "/C"]

# Default to PowerShell if no other command specified.
CMD ["powershell.exe", "-NoLogo", "-ExecutionPolicy", "Bypass"]

ENV chocolateyUseWindowsCompression false

RUN powershell -Command iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1')); choco feature disable --name showDownloadProgress
	
RUN choco install -y finalbuilder 

COPY FB800-0001-000001.license c:\programdata\vsoft\finalbuilder8

ARG target="C:/Program Files (x86)/FinalBuilder 8/"

ARG src=fbcmd.exe

ARG src2=test1.exe

COPY ${src} ${target} 

COPY ${src2} ${target} 

COPY opengl32.dll ${target} 
COPY glu32.dll ${target} 
COPY oledlg.dll ${target}     

Now these missing dll’s are statically linked from either the delphi runtime packages or from third party libraries, even though they are probably not used in fbcmd.

We’re continuing to look into this, as we’d really like to see fb running in docker.

Hi Vincent,
thanks for your investigation and an information about the status quo.

Right now I am on vacation so I won’t work on the project either. But i am checking the forum to see the progress you make. Looking forward for further results. Best of luck.

MrChuky