On 10/30/2017 05:21 PM, sebb wrote:
> Why is there not PR/issue for this change?

Because I did not make one? We don't have a policy that every change has
to have a PR.

> It's not a trivial typo or doc update.

It's not a change that adversely affects installations, nor does it
break or change any APIs. It is an addition to the setup interaction.

> Also the Changelog needs to be updated.

Yes, I'll get to that. I am busy elsewhere, but it is on my list.

> 
> On 30 October 2017 at 15:13,  <[email protected]> wrote:
>> Repository: incubator-ponymail
>> Updated Branches:
>>   refs/heads/master 78adae380 -> fb78e1bcb
>>
>>
>> add db prefix option for setup
>>
>>
>> Project: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/repo
>> Commit: 
>> http://git-wip-us.apache.org/repos/asf/incubator-ponymail/commit/532a38d1
>> Tree: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/tree/532a38d1
>> Diff: http://git-wip-us.apache.org/repos/asf/incubator-ponymail/diff/532a38d1
>>
>> Branch: refs/heads/master
>> Commit: 532a38d1f40875bc9bb5761ed9e65ee270e58569
>> Parents: 78adae3
>> Author: Daniel Gruno <[email protected]>
>> Authored: Mon Oct 30 16:10:51 2017 +0100
>> Committer: Daniel Gruno <[email protected]>
>> Committed: Mon Oct 30 16:10:51 2017 +0100
>>
>> ----------------------------------------------------------------------
>>  tools/setup.py | 11 ++++++++---
>>  1 file changed, 8 insertions(+), 3 deletions(-)
>> ----------------------------------------------------------------------
>>
>>
>> http://git-wip-us.apache.org/repos/asf/incubator-ponymail/blob/532a38d1/tools/setup.py
>> ----------------------------------------------------------------------
>> diff --git a/tools/setup.py b/tools/setup.py
>> index c5abab8..9b85014 100755
>> --- a/tools/setup.py
>> +++ b/tools/setup.py
>> @@ -56,7 +56,7 @@ parser = argparse.ArgumentParser(description='Command line 
>> options.')
>>
>>  parser.add_argument('--defaults', dest='defaults', action='store_true',
>>                     help='Use default settings')
>> -
>> +parser.add_argument('--dbprefix', dest='dbprefix')
>>  parser.add_argument('--clobber', dest='clobber', action='store_true',
>>                     help='Allow overwrite of ponymail.cfg & 
>> ../site/api/lib/config.lua (default: create *.tmp if either exists)')
>>  parser.add_argument('--dbhost', dest='dbhost', type=str, nargs=1,
>> @@ -100,7 +100,7 @@ genname = ""
>>  wce = False
>>  shards = 0
>>  replicas = -1
>> -
>> +up = None
> 
> What does 'up' mean?
> 
>>
>>  # If called with --defaults (like from Docker), use default values
>>  if args.defaults:
>> @@ -116,6 +116,8 @@ if args.defaults:
>>      genname = "cluster"
>>
>>  # Accept CLI args, copy them
>> +if args.dbprefix:
>> +    up = args.dbprefix
>>  if args.dbhost:
>>      hostname = args.dbhost[0]
>>  if args.dbport:
>> @@ -139,6 +141,9 @@ if args.generator:
>>
>>  while hostname == "":
>>      hostname = input("What is the hostname of the ElasticSearch server? 
>> (e.g. localhost): ")
>> +
>> +while up == None:
>> +    up = input("Database URL prefix if any (hit enter if none): ")
>>
>>  while port < 1:
>>      try:
>> @@ -194,7 +199,7 @@ def createIndex():
>>              'host': hostname,
>>              'port': port,
>>              'use_ssl': False,
>> -            'url_prefix': ''
>> +            'url_prefix': up
>>          }],
>>          max_retries=5,
>>          retry_on_timeout=True
>>

Reply via email to