bootstrapping user tools

5 views
Skip to first unread message

Jeffrey Collyer

unread,
Aug 12, 2010, 11:45:57 AM8/12/10
to roster-discussion
So I have my rosterd server up and running, next step is to get the
user tools and make some test data. Unfortunately the install
instructions aren't showing me how to get that user tools configured
properly.

The wiki says
# roster-user-tools-bootstrap -s <server> -c <config_file>

so

roster-user-tools# ./scripts/roster_user_tools_bootstrap -s localhost -
c /usr/local/etc/roster_user_tools.conf
Traceback (most recent call last):
File "./scripts/roster_user_tools_bootstrap", line 83, in <module>
main(sys.argv[1:])
File "./scripts/roster_user_tools_bootstrap", line 80, in main
config_file_object.write(open(options.config_file, 'wb'))
TypeError: coercing to Unicode: need string or buffer, NoneType found

I also tried adding the roster_user_tools.conf file by hand with the
contents of :

[user_tools]
cred_file = /usr/local/etc/roster_dns_cred
server = localhost

but that didn't help. And there don't seem to be explicit
instructions on how to generate a credential file, although I do find
a dnscredential script without the execute bit on in the roster-user-
tools/scripts directory.

I'll keep poking around, but any help here would be appreciated.

Jeff

Jake

unread,
Aug 12, 2010, 12:06:42 PM8/12/10
to roster-discussion
The proper flag is --config-file. -c is for a credential file flag
that should not be in the tool anyway. I will proceed to make this
fix. But for the time being you can use the --config-file flag.
Currently config files are limited to a few specific locations. It can
be in ~/.rosterrc or /etc/roster/roster_user_tools.conf. I am
currently adding an environment variable to add ability to change
this.

Jake

unread,
Aug 12, 2010, 12:18:51 PM8/12/10
to roster-discussion
If you update your tree to merge the last change I made in trunk, you
can move your config file wherever you like and set a
ROSTER_USER_CONFIG environment variable of its location.

On Aug 12, 11:45 am, Jeffrey Collyer <forlo...@gmail.com> wrote:

Jeffrey Collyer

unread,
Aug 12, 2010, 3:10:45 PM8/12/10
to roster-d...@googlegroups.com
Jake,
Thanks for the quick update on this. I 'svn update'd my tree and
installed the changes. Unfortunately still no joy.

export ROSTER_USER_CONFIG=/usr/local/etc/roster_user_tools.conf

roster-user-tools# scripts/roster_user_tools_bootstrap -s localhost
--config-file=/usr/local/etc/roster_user_tools.conf


/usr/local/etc/roster_user_tools.conf
Traceback (most recent call last):

File "scripts/roster_user_tools_bootstrap", line 84, in <module>
main(sys.argv[1:])
File "scripts/roster_user_tools_bootstrap", line 78, in main
config_file_object.set(section, 'cred_file', options.credfile)
AttributeError: Values instance has no attribute 'credfile'

this happens whether or not I use the --config-file= flag on the command
line.

Jeff

Jake

unread,
Aug 13, 2010, 8:12:26 AM8/13/10
to roster-discussion
I have just tested the environment variable and it works just fine. If
you have version 0.14 rather than trunk you will need to merge the
change and reinstall. If you are running trunk, svn up'ed and have not
reinstalled Roster please do so. Otherwise you can always put the
config file in /etc/roster/roster_user_tools.conf or ~/.rosterrrc

Jeffrey Collyer

unread,
Sep 10, 2010, 3:23:48 PM9/10/10
to roster-discussion
Jake,
Sorry for the late reply. Back to School tasks finally completed,
I now have some more time to devote to roster. I'm still failing to
get the user tools installed correctly.

I have "svn up" to the current release. And used python to resintall
the user tools. I have the server up and running with its config in /
etc/roster/roster_server.conf. My intention is to let the user config
live in that directory as well.

/usr/local/src/roster-dns-management/roster-user-tools# scripts/
roster_user_tools_bootstrap --server=localhost

Traceback (most recent call last):
File "scripts/roster_user_tools_bootstrap", line 83, in <module>
main(sys.argv[1:])
File "scripts/roster_user_tools_bootstrap", line 77, in main
config_file_object.set(section, 'cred_file', options.credfile)
File "/usr/lib/python2.6/ConfigParser.py", line 659, in set
raise TypeError("option values must be strings")
TypeError: option values must be strings

Do I need a blank or template user config file in place before trying
to bootstrap? The error appears to be failing to set something in the
credential file, or possibly the credential file name itself. This
happens whether or not I set the ROSTER_USER_CONFIG environment
variable, or have a blank file or no file in place for
roster_user_tools.conf

Jeff

Jake

unread,
Oct 1, 2010, 11:20:50 AM10/1/10
to roster-discussion
The config file flag is a config file location. This is just a string
of where the generated config file will go.
Reply all
Reply to author
Forward
0 new messages