so, im trying to get the server to run in a linux docker using mono (see my latest build https://hub.docker.com/r/aaronstar/mono/builds/buf8cwxwmb53dfqjmjpryte/). I have it generally set up, my only problem is that when running the non gui version, (mono EmpyrionLauncher.exe -startDedi) i get an error about it not being able to display something... Spoiler: the error has been put in a spoiler to decrease post size Unhandled Exception: System.TypeInitializationException: The type initializer for 'System.Windows.Forms.XplatUI' threw an exception. ---> System.ArgumentNullException: Could not open display (X-Server required. Check your DISPLAY environment variable) Parameter name: Display at System.Windows.Forms.XplatUIX11.SetDisplay (System.IntPtr display_handle) [0x00408] in <8254e6010dae4d09ac0767af6dcc75af>:0 at System.Windows.Forms.XplatUIX11..ctor () [0x00077] in <8254e6010dae4d09ac0767af6dcc75af>:0 at System.Windows.Forms.XplatUIX11.GetInstance () [0x00019] in <8254e6010dae4d09ac0767af6dcc75af>:0 at System.Windows.Forms.XplatUI..cctor () [0x00066] in <8254e6010dae4d09ac0767af6dcc75af>:0 --- End of inner exception stack trace --- at System.Windows.Forms.Application.EnableVisualStyles () [0x00006] in <8254e6010dae4d09ac0767af6dcc75af>:0 at EmpyrionLauncher.Program.Main () [0x00000] in <d3dc0aac6d5a407b863c192ccb3f9a6d>:0 [ERROR] FATAL UNHANDLED EXCEPTION: System.TypeInitializationException: The type initializer for 'System.Windows.Forms.XplatUI' threw an exception. ---> System.ArgumentNullException: Could not open display (X-Server required. Check your DISPLAY environment variable) Parameter name: Display at System.Windows.Forms.XplatUIX11.SetDisplay (System.IntPtr display_handle) [0x00408] in <8254e6010dae4d09ac0767af6dcc75af>:0 at System.Windows.Forms.XplatUIX11..ctor () [0x00077] in <8254e6010dae4d09ac0767af6dcc75af>:0 at System.Windows.Forms.XplatUIX11.GetInstance () [0x00019] in <8254e6010dae4d09ac0767af6dcc75af>:0 at System.Windows.Forms.XplatUI..cctor () [0x00066] in <8254e6010dae4d09ac0767af6dcc75af>:0 --- End of inner exception stack trace --- at System.Windows.Forms.Application.EnableVisualStyles () [0x00006] in <8254e6010dae4d09ac0767af6dcc75af>:0 at EmpyrionLauncher.Program.Main () [0x00000] in <d3dc0aac6d5a407b863c192ccb3f9a6d>:0 so either the no gui version just hides the gui, or i typed the startup command wrong... I would appreciate any help
1. in order for the server to be compatible with the web panel I'm using it has to be a console type output 2. the gui is not very useful, you can only make announcements and shutdown, you cant issue any other commands 3. this is a Linux server os, so there is no way to make a gui, that is why we are getting the error. it is trying to generate a gui, even though it is not supposed to
yes, as i said, i am using the command to start the server without a gui, however, for some reason it is still complaining about not being able to make a gui. so either i typed the startup command wrong (not likely) or when you run the guiless version it still makes a gui, and just does not show it
It sounds like your suspicion that the gui is being created and then hidden is correct. In that case, you might see if the virtual x display you get from xvfb or similar is enough to get it to run.
newest build in progress: https://hub.docker.com/r/aaronstar/mono/builds/bgqvvnrp3fbzarebzwdphhv/ lets see if this works...
strange... i installed xvfb, then ran it before starting the gameserver, but i got command not found...
I tried using WINE and PlayOnLinux to get a dedicated server to run, with no GUI...never succeeded. Please let me know when you do, and what you had to go through!
Hi ! (Hope my answer isnt too late. Perhaps you managed to make it run now..? ) I got a Bi Xeon with 16 cores at home and I also wanted to try install empyrion server on a virtualized linux VM over proxmox. I searched a bit at your error, and perhaps it needs a full X11 implementation on the machine. Perhaps xvfb isn't enough ? In this stack overflow reply: https://stackoverflow.com/a/31331381 It says : "Mono's Windows Forms implementation requires X11 to be present on Linux. As this is a headless instance like you described, it just fails to meet the requirements and leads to the exceptions." Then the OP states he installed a full Gnome UI and then it worked. Perhaps this the solution ? Did you tried it too ?
Found this too.. Code: xvfb-run --auto-servernum --server-args='-screen 0 640x480x24:32' myUnityApplication -batchmode from https://answers.unity.com/questions/353653/can-a-unity-game-be-started-over-ssh.html
My guess is that you're going to have to load up X11 into your Docker container, because it's trying to access it, and failing. I would also report this as a bug. I'll try and run 'true headless' on my Windows box, and see if the GUI pops up. Thanks for bashing on this!
Any update on this container ? I would really interested in testing something like that on my home server too