Skip to content

Commit

Permalink
clientPort warning if <1024
Browse files Browse the repository at this point in the history
  • Loading branch information
andreisavu committed Jul 16, 2010
1 parent 562b74c commit dd77c63
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions zoocfg.py
Expand Up @@ -136,6 +136,9 @@ def check(cls, cfg):
elif not isinstance(cfg.clientPort, int) or cfg.clientPort < 0 or cfg.clientPort > 65535:
errors.append('`clientPort` should be a valid TCP/IP port number.')

elif cfg.clientPort < 1024:
warnings.append('`clientPort` < 1024. You should not run ZooKeeper using the root account')

return warnings, errors

class TickTime(BaseRule):
Expand Down

0 comments on commit dd77c63

Please sign in to comment.