mateuszy - 2006-08-18

Hello!

I am using Ant to run and install an application. The application will be run as a NT Service on different accounts. So, I decided to use wrapper.ntserice.password.prompt property (because it hides a password while typing)

The problem is that when I invoke Ant function exec to install the service, the prompt asking for password doesn't appear on the screen. User doesn't have also any possibility to type anything and application just halts. From the debug I can see, that application stops right in this moment:

DEBUG  | wrapper  | 2006/08/17 14:31:25 | Working directory set to: \o9/app\symulacja_przelicznika
DEBUG  | wrapper  | 2006/08/17 14:31:25 | Service command: C:\o9\bin\wrapper\wrapper-windows-x86-32.exe -s C:\o9\conf\instances\symulacja_przelicznika\wrapper.configuration.wrp wrapper.debug=true wrapper.working.dir=\o9/app\symulacja_przelicznika
DEBUG  | wrapper  | 2006/08/17 14:31:25 | Prompting for account password...

Ofcourse, installation of the service works fine, when I'm not using ant (just type the commands on console). Also, when I delete the line
wrapper.ntservice.password.prompt=TRUE
the problem dissapears.

So, the problem must be something about using standard IO by Wrapper and by Ant at the same time...

Can anyone help me? Have anyone had similar situation?

Thanks a lot!

I'll add that  the Ant script command I'm using looks like that (all the properties are set):

-------------------------------------------------
           <exec executable="${o2.bin}\wrapper\wrapper-windows-x86-32.exe" os="${accepted.windows.versions}" newenvironment="true" dir="${o2.instances}\${instance}">
            <arg line="-i ${o2.conf}/instances/${instance}/wrapper.configuration.wrp wrapper.debug=true wrapper.working.dir=${o2.instances}\${instance}"/>
        </exec>
--------------------------------------------------

And the wrapper config file contains following
part:

--------------------------------------------------

#********************************************************************
# Wrapper Logging Properties
#********************************************************************
wrapper.console.format=PM
wrapper.console.loglevel=INFO

# Log file to use for wrapper output logging.
wrapper.logfile=\o9/log/symulacja_przelicznika/wrapper.log
wrapper.logfile.format=LPTM
wrapper.logfile.loglevel=INFO
wrapper.logfile.maxsize=0
wrapper.logfile.maxfiles=0

# Log Level for sys/event log output.  (See docs for log levels)
wrapper.syslog.loglevel=NONE

#********************************************************************
# Wrapper Windows Properties
#********************************************************************
# Title to use when running as a console
wrapper.console.title=symulacja_przelicznika

#********************************************************************
# Wrapper Windows NT/2000/XP Service Properties
#********************************************************************
# WARNING - Do not modify any of these properties when an application
#  using this configuration file has been installed as a service.
#  Please uninstall the service before modifying this section.  The
#  service can then be reinstalled.

# Name of the service
wrapper.ntservice.name=symulacja_przelicznika

# Display name of the service
wrapper.ntservice.displayname=symulacja_przelicznika

# Account properties

wrapper.ntservice.account=.\MackieMajcher
wrapper.account.password.prompt=TRUE

# Description of the service
wrapper.ntservice.description=

# Service dependencies.  Add dependencies as needed starting from 1
#wrapper.ntservice.dependency.1=

# Mode in which the service is installed.  AUTO_START or DEMAND_START
wrapper.ntservice.starttype=AUTO_START

# Allow the service to interact with the desktop.
wrapper.ntservice.interactive=false

-------------------------------------------------

cheers!

Mateuszy