<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">2017-12-29 16:53 GMT+01:00 Denis Kudriashov <span dir="ltr"><<a href="mailto:dionisiydk@gmail.com" target="_blank">dionisiydk@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><span>2017-12-29 16:13 GMT+01:00 Andrei Stebakov <span dir="ltr"><<a href="mailto:lispercat@gmail.com" target="_blank">lispercat@gmail.com</a>></span>:<br></span><div class="gmail_extra"><div class="gmail_quote"><span><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Nicolai, the maximize/non-maximize trick worked! Thanks! I wonder if it's an easy fix to put in Pharo.</div></blockquote><div><br></div></span><div>So it means that something in image is not initialised. It can be another bug of wrong startup order</div></div></div></div></blockquote><div><br></div><div><br></div><div>Maybe a problem on the image and the vm side.<br></div><div><br>Even in headless mode, starting pharo creates a window. Even if it is hidden, it has some size.<br></div><div><br>Quit and Saving an image will write the current width/height into the image file.<br><br></div><div>Starting the vm will create a window and set the size of the window to the last size.<br></div><div>The window is always created in normal (not-maximized) mode and the available size is a little bit smaller <br></div><div>than for a maximized window.<br><br></div><div>Now, the image checks for a change of the size of the current DisplayScreen instance and the actual screen size.<br></div><div>If this is different (as in this case) a new DisplayScreen is initialized which will call a full screen update (<span class="gmail-pl-en">ioForceDisplayUpdate<span class="">)</span>.<br><br></span></div><div><span class="gmail-pl-en">And this method will show a hidden (headless) image.<br><br><br></span></div><div><br></div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div><div class="gmail-m_6174135899497619841h5"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 29, 2017 at 6:22 AM, <a href="mailto:phil@highoctane.be" target="_blank">phil@highoctane.be</a> <span dir="ltr"><<a href="mailto:phil@highoctane.be" target="_blank">phil@highoctane.be</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>I am using nssm because the service option is broken.</div><div><br></div><div>The code seems to still be in the image but disabled (there are quite a few things like that actually).</div><span class="gmail-m_6174135899497619841m_2537493881744409017m_6328781192649063858HOEnZb"><font color="#888888"><div><br></div><div>Phil</div><div><br></div></font></span></div><div><div class="gmail-m_6174135899497619841m_2537493881744409017h5"><div class="gmail-m_6174135899497619841m_2537493881744409017m_6328781192649063858HOEnZb"><div class="gmail-m_6174135899497619841m_2537493881744409017m_6328781192649063858h5"><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 29, 2017 at 11:59 AM, Torsten Bergmann <span dir="ltr"><<a href="mailto:astares@gmx.de" target="_blank">astares@gmx.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
Hi, (cross posting vm-dev)<br>
<br>
nssm is nice - but requires additional tools.<br>
<br>
Since the days of Squeak the windows VM had the<br>
<br>
 -service "ServiceName"<br>
<br>
option and one was able to run Squeak as a windows service out of the box.<br>
<br>
See <a href="http://wiki.squeak.org/squeak/105" rel="noreferrer" target="_blank">http://wiki.squeak.org/squeak/<wbr>105</a> for details.<br>
<br>
This option allows to register/deregister with the windows service manager and run<br>
a headless image.<br>
<br>
I run a Squeak Wiki (Swiki/Comanche) since years with this and it is very nice and stable.<br>
<br>
Unfortunately this is broken in recent Pharo VMs and so far Esteban or others did not<br>
have the time to look into this issue. Would be really nice if this option could<br>
be recovered in 2018. So one could easily deploy and run Seaside or Teapot/Tealight<br>
or Zinc/WebClient based web services on Windows.<br>
<br>
If we want to deploy Smalltalk based web applications or services on Windows we<br>
should support that. It will keep Windows administrators happy and we would integrate with<br>
the whole ecosystem (for instance you can start/stop a service using Windows scripting for<br>
doing backups, etc.) right out of the box.<br>
<br>
Bye<br>
T.<br>
 <br>
 <br>
<br>
Gesendet: Freitag, 29. Dezember 2017 um 11:36 Uhr<br>
Von: "<a href="mailto:phil@highoctane.be" target="_blank">phil@highoctane.be</a>" <<a href="mailto:phil@highoctane.be" target="_blank">phil@highoctane.be</a>><br>
An: "Any question about pharo is welcome" <<a href="mailto:pharo-users@lists.pharo.org" target="_blank">pharo-users@lists.pharo.org</a>><br>
Betreff: Re: [Pharo-users] Running headless on Windows<br>
<br>
If you want to run Pharo as a service, I have found nssm to be working well.<br>
 <a href="https://nssm.cc" rel="noreferrer" target="_blank">https://nssm.cc</a><br>
 <br>
Phil<br>
 <br>
On Dec 29, 2017 09:25, "Nicolai Hess" <<a href="mailto:nicolaihess@gmail.com" target="_blank">nicolaihess@gmail.com</a>[mailto:<a href="mailto:nicolaihess@gmail.com" target="_blank"><wbr>nicolaihess@gmail.com</a>]> wrote:<br>
 <br>
 <br>
2017-12-29 3:07 GMT+01:00 Andrei Stebakov <<a href="mailto:lispercat@gmail.com" target="_blank">lispercat@gmail.com</a>[mailto:<a href="mailto:lispercat@gmail.com" target="_blank">li<wbr>spercat@gmail.com</a>]>:<br>
Pierce, I tried all of those "no display" options, the result is the same<br>
<br>
 <br>
On Dec 28, 2017 8:37 PM, "Pierce Ng" <<a href="mailto:pierce@samadhiweb.com" target="_blank">pierce@samadhiweb.com</a>[mailto:<a href="mailto:pierce@samadhiweb.com" target="_blank"><wbr>pierce@samadhiweb.com</a>]> wrote:On Wed, Dec 27, 2017 at 04:58:39PM +0100, Cyril Ferlicot D. wrote:<br>
> On 12/27/2017 04:39 PM, Andrei Stebakov wrote:<br>
> > When I run Pharo 6.1 with -- headless option on Windows, it executes the<br>
> > eval command as expected but during the execution (which lasts 4 sec) it<br>
> > opens the Pharo GUI. <br>
> > Is it expected? I thought headless means that the whole execution would<br>
> > happen in the background<br>
><br>
> I think that currently Pharo does not have a "real" headless. But I<br>
> heard there was work on that part for Pharo 7.<br>
<br>
I know OP is talking about Windows...  I've been running server applications on<br>
Linux without X11 with -vm-display-null and in-image RFBServer for access to<br>
Pharo over VNC. This works very well for me.<br>
<br>
I believe "real" headless means GUI is not run at all and therefore does not<br>
consume CPU cycles, which is very welcome. Meanwhile, maybe -vm-display-null<br>
works on Windows for scripting purposes?<br>
<br>
Pierce<br>
<br>
 <br>
 <br>
Hi Andrei,<br>
 <br>
can you try this:<br>
 <br>
Open Pharo normal (no headless option).<br>
Change the window size to "not-maximized" (eve if it is actually not maximized, maximize it ones and change it back to "not-maximized")<br>
Save and quit the image.<br>
 <br>
After that, a call like<br>
 <br>
pharo --headless pharo.image eval "DateAndTime now"<br>
will write the output to the stdout file, without opening a window.<br>
<br>
<br>
 <br>
 <br>
 <br>
</blockquote></div><br></div>
</div></div></div></div></blockquote></div><br></div>
</blockquote></div></div></div><br></div></div>
</blockquote></div><br></div></div>