Thanks, full paths worked, but had a limited set of folders to work in. For example, I had originally tried "C:\Program Files\mosquitto\ pwfile.example", and "C:\Users\<username>\AppData\Roaming\mosquitto\pwfile.example" (both with and without the quotes) and it didn't work.
I did end up getting it to work in C:\ProgramData\mosquitto\pwfile.example. So I suspect the paths accessible by Windows services are limited. Still, environment variables would be nice, so I could do %ProgramData%\mosquitto\myapp.conf Thanks, Steve On Thu, Aug 1, 2013 at 10:42 AM, Roger Light <ro...@atchoo.org> wrote: > Hi Steve, > > I can't look at this until later, but I'd suggest using a complete > path rather than using %APPDATA% for now. I'll see about fixing it so > that the path can contain an environment variable for version 1.2, > which should be available any day now. > > Cheers, > > Roger > > > On Wed, Jul 31, 2013 at 7:34 PM, Steven Luke <stevejl...@gmail.com> wrote: > > I am trying to set up user authentication on my mosquitto server, so I > > figured I would start with using the already provided password file. > > > > *** in the conf file *** > > allow_anonymous false > > password_file pwfile.example > > > > > > This works when I run mosquitto from the command line: > > > > C:\Program Files\mosquitto>mosquitto -c mosquitto.conf > > > > When I launch mosquitto this way, I mosquitto starts and I need to log > in to > > subscribe or publish messages. But when I try to start the Windows > service > > I get an error in the logs saying it can't find the password file. The > path > > to the service points to the same directory as above. I have tried > changing > > the path to %APPDATA%\mosquitto\pwfile.example and putting the file in > > <User>\AppData\Roaming\mosquitto\ or <User>\AppData\Local\mosquitto\ but > to > > no avail. > > > > So, anyone know where I should put the password file to allow the Windows > > Service to run? > > > > OS: Windows 7, and Windows Vista. 32 bit. Mosquitto version 1.1.2. > > > > Thanks for any help, > > Steve > > > > -- > > Mailing list: https://launchpad.net/~mosquitto-users > > Post to : mosquitto-users@lists.launchpad.net > > Unsubscribe : https://launchpad.net/~mosquitto-users > > More help : https://help.launchpad.net/ListHelp > > >
-- Mailing list: https://launchpad.net/~mosquitto-users Post to : mosquitto-users@lists.launchpad.net Unsubscribe : https://launchpad.net/~mosquitto-users More help : https://help.launchpad.net/ListHelp