VirtualMailManager/cli/clihelp.py
changeset 606 ab97727357a4
child 608 0ed93eb8b364
equal deleted inserted replaced
605:b994444f7dee 606:ab97727357a4
       
     1 # -*- coding: UTF-8 -*-
       
     2 # Copyright (c) 2012, Pascal Volk
       
     3 # See COPYING for distribution information.
       
     4 """
       
     5     VirtualMailManager.cli.vmmhelp
       
     6     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       
     7 
       
     8     Virtual Mail Manager's command line help.
       
     9 """
       
    10 
       
    11 _ = lambda msg: msg
       
    12 
       
    13 
       
    14 help_msgs = {'configget': (_(u"""This subcommand is used to display the
       
    15 actual value of the given configuration <option>."""),),
       
    16     # configset
       
    17     'configset': (_(u"""Use this subcommand to set or update a single
       
    18 configuration option's value. <option> is the configuration option, <value>
       
    19 is the <option>'s new value."""),
       
    20 _(u"""Note: This subcommand will create a new vmm.cfg without any comments.
       
    21 Your current configuration file will be backed as vmm.cfg.bak."""),),
       
    22     # configure
       
    23     'configure': (_(u"""Starts the interactive configuration for all
       
    24 configuration sections."""),
       
    25 _(u"""In this process the currently set value of each option will be displayed
       
    26 in square brackets. If no value is configured, the default value of each
       
    27 option will be displayed in square brackets. Press the return key, to accept
       
    28 the displayed value."""),
       
    29 _(u"""If the optional argument <section> is given, only the configuration
       
    30 options from the given section will be displayed and will be configurable.
       
    31 The following sections are available:
       
    32 """),
       
    33 """    account, bin, database, domain, mailbox, misc""",
       
    34 _(u"""All configuration options are described in vmm.cfg(5)."""),
       
    35 _(u"""Note: This subcommand will create a new vmm.cfg without any comments.
       
    36 Your current configuration file will be backed as vmm.cfg.bak."""),),
       
    37     # getuser
       
    38     'getuser': (_(u"""If only the <uid> is available, for example from process
       
    39 list, the subcommand getuser will show the user's address."""),),
       
    40     # listdomains
       
    41     'listdomains': (_(u"""This subcommand lists all available domains. All
       
    42 domain names will be prefixed either with `[+]', if the domain is a primary
       
    43 domain, or with `[-]', if it is an alias domain name. The output can be
       
    44 limited with an optional <pattern>."""),
       
    45 _(u"""To perform a wild card search, the % character can be used at the start
       
    46 and/or the end of the <pattern>."""),),
       
    47     # listpwschemes
       
    48     'listpwschemes': (_(u"""This subcommand lists all password schemes which
       
    49 could be used in the vmm.cfg as value of the misc.password_scheme option.
       
    50 The output varies, depending on the used Dovecot version and the system's
       
    51 libc."""),
       
    52 _(u"""When your Dovecot installation isn't too old, you will see additionally
       
    53 a few usable encoding suffixes. One of them can be appended to the password
       
    54 scheme."""),),
       
    55     # version
       
    56     'version': (_(u"""Prints vmm's version and copyright information to stdout.
       
    57 After this vmm exits."""),),
       
    58     # domainadd
       
    59     'domainadd': (_(u"""Adds the new domain into the database and creates the
       
    60 domain directory."""),
       
    61 _(u"""If the optional argument <transport> is given, it will override the
       
    62 default transport (domain.transport) from vmm.cfg. The specified <transport>
       
    63 will be the default transport for all new accounts in this domain."""),
       
    64 _(u"""Configuration-related behavior:"""),
       
    65 u""" * domain.auto_postmaster""",
       
    66 _(u"""When that option is set to true (default) vmm will automatically create
       
    67 the postmaster account for the new domain and prompt for postmaster@<fqdn>'s
       
    68 password."""),
       
    69 u""" * account.random_password""",
       
    70 _(u"""When the value of that option is also set to true, vmm will automatically
       
    71 create the postmaster account for the new domain and print the generated
       
    72 postmaster password to stdout."""),),
       
    73     # domaindelete
       
    74     'domaindelete': (_(u"""This subcommand deletes the domain specified by
       
    75 <fqdn>."""),
       
    76 _(u"""If there are accounts, aliases and/or relocated users assigned to the
       
    77 given domain, vmm will abort the requested operation and show an error
       
    78 message. If you know, what you are doing, you can specify the optional keyword
       
    79 'force'."""),
       
    80 _(u"""If you really always know what you are doing, edit your vmm.cfg and set
       
    81 the option domain.force_deletion to true."""),),
       
    82     # domaininfo
       
    83     'domaininfo': (_(u"""This subcommand shows some information about the
       
    84 given domain."""),
       
    85 _(u"""For a more detailed information about the domain the optional argument
       
    86 <details> can be specified. A possible <details> value can be one of the
       
    87 following six keywords:"""),
       
    88 """    accounts, aliasdomains, aliases, catchall, relocated, full""",),
       
    89     # domainquota
       
    90     'domainquota': (_(u"""This subcommand is used to configure a new quota
       
    91 limit for the accounts of the domain - not for the domain itself."""),
       
    92 _(u"""The default quota limit for accounts is defined in the vmm.cfg
       
    93 (domain.quota_bytes and domain.quota_messages)."""),
       
    94 _(u"""The new quota limit will affect only those accounts for which the limit
       
    95 has not been overridden. If you want to restore the default to all accounts,
       
    96 you may pass the keyword 'force'. When the argument <messages> was omitted the
       
    97 default number of messages 0 (zero) will be applied."""),),
       
    98     # domainservices
       
    99     'domainservices': (_(u"""To define which services could be used by the
       
   100 users of the domain — with the given <fqdn> — use this subcommand."""),
       
   101 _(u"""Each specified <service> will be enabled/usable. All other services
       
   102 will be deactivated/unusable. Possible <service> names are:"""),
       
   103 u"""    imap, pop3, sieve, smtp""",
       
   104 _(u"""The new service set will affect only those accounts for which the set has
       
   105 not been overridden. If you want to restore the default to all accounts, you
       
   106 may pass the keyword 'force'."""),),
       
   107     # domaintransport
       
   108     'domaintransport': (_(u"""A new transport for the indicated domain can be
       
   109 set with this subcommand."""),
       
   110 _(u"""The new transport will affect only those accounts for which the transport
       
   111 has not been overridden. If you want to restore the default to all accounts,
       
   112 you may pass the keyword 'force'."""),),
       
   113     # domainnote
       
   114     'domainnote': (_(u"""With this subcommand, it is possible to attach a
       
   115 note to the specified domain. Without an argument, an existing note is
       
   116 removed."""),),
       
   117     # aliasdomainadd
       
   118     'aliasdomainadd': (_(u"""This subcommand adds the new alias domain
       
   119 (<fqdn>) to the destination <domain> that should be aliased."""),),
       
   120     # aliasdomaindelete
       
   121     'aliasdomaindelete': (_(u"""Use this subcommand if the alias domain
       
   122 <fqdn> should be removed."""),),
       
   123     # aliasdomaininfo
       
   124     'aliasdomaininfo': (_(u"""This subcommand shows to which domain the alias
       
   125 domain <fqdn> is assigned to."""),),
       
   126     # aliasdomainswitch
       
   127     'aliasdomainswitch': (_(u"""If the destination of the existing alias
       
   128 domain <fqdn> should be switched to another <destination> use this
       
   129 subcommand."""),),
       
   130     # useradd
       
   131     'useradd': (_(u"""Use this subcommand to create a new e-mail account for
       
   132 the given <address>."""),
       
   133 _(u"""If the <password> is not provided, vmm will prompt for it interactively.
       
   134 When no <password> is provided and account.random_password is set to true, vmm
       
   135 will generate a random password and print it to stdout after the account has
       
   136 been created."""),),
       
   137     # userdelete
       
   138     'userdelete': (_(u"""Use this subcommand to delete the account with the
       
   139 given <address>."""),
       
   140 _(u"""If there are one or more aliases with an identical destination address,
       
   141 vmm will abort the requested operation and show an error message. To prevent
       
   142 this, specify the optional keyword 'force'."""),),
       
   143     # userinfo
       
   144     'userinfo': (_(u"""This subcommand displays some information about the
       
   145 account specified by <address>."""),
       
   146 _(u"""If the optional argument <details> is given some more information will be
       
   147 displayed. Possible values for <details> are:"""),
       
   148 u"""    aliases, du. full""",),
       
   149     # username
       
   150     'username': (_(u"""The user's real <name> can be set/updated with this
       
   151 subcommand."""),
       
   152 _(u"""If no <name> is given, the value stored for the account is erased."""),
       
   153 ),
       
   154     # userpassword
       
   155     'userpassword': (_(u"""The password of an account can be updated with this
       
   156 subcommand."""),
       
   157 _(u"""If no <password> was provided, vmm will prompt for it interactively."""),
       
   158 ),
       
   159     # usernote
       
   160     'usernote': (_(u"""With this subcommand, it is possible to attach a note
       
   161 to the specified account. Without an argument, an existing note is
       
   162 removed."""),),
       
   163     # userquota
       
   164     'userquota': (_(u"""This subcommand is used to set a new quota limit for
       
   165 the given account."""),
       
   166 _(u"""When the argument <messages> was omitted the default number of messages
       
   167 0 (zero) will be applied."""),
       
   168 _(u"""Instead of <storage> pass the keyword 'domain' to remove the
       
   169 account-specific override, causing the domain's value to be in effect."""),),
       
   170     # userservices
       
   171     'userservices': (_(u"""To grant a user access to the specified services,
       
   172 use this command."""),
       
   173 _(u"""All omitted services will be deactivated/unusable for the user with the
       
   174 given <address>."""),
       
   175 _(u"""Instead of <service> pass 'domain' to remove the account-specific
       
   176 override, causing the domain's value to be in effect."""),),
       
   177     # usertransport
       
   178     'usertransport': (_(u"""A different <transport> for an account can be
       
   179 specified with this subcommand."""),
       
   180 _(u"""Instead of <transport> pass 'domain' to remove the account-specific
       
   181 override, causing the domain's value to be in effect."""),),
       
   182     # aliasadd
       
   183     'aliasadd': (_(u"""This subcommand is used to create a new alias
       
   184 <address> with one or more <destination> addresses."""),
       
   185 _(u"""Within the destination address, the placeholders '%n', '%d', and '%='
       
   186 will be replaced by the local part, the domain, or the email address with '@'
       
   187 replaced by '=' respectively. In combination with alias domains, this enables
       
   188 domain-specific destinations."""),),
       
   189     # aliasinfo
       
   190     'aliasinfo': (_(u"""Information about the alias with the given <address>
       
   191 can be displayed with this subcommand."""),),
       
   192     # relocatedadd
       
   193     'relocatedadd': (_(u"""A new relocated user can be created with this
       
   194 subcommand."""),
       
   195 _(u"""<address> is the user's ex-email address, for example
       
   196 b.user@example.com, and <newaddress> points to the new email address where
       
   197 the user can be reached."""),),
       
   198     # relocatedinfo
       
   199     'relocatedinfo': (_(u"""This subcommand shows the new address of the
       
   200 relocated user with the given <address>."""),),
       
   201     # relocateddelete
       
   202     'relocateddelete': (_(u"""Use this subcommand in order to delete the
       
   203 relocated user with the given <address>."""),),
       
   204     # catchalladd
       
   205     'catchalladd': (_(u"""This subcommand allows to specify destination
       
   206 addresses for a domain, which shall receive mail addressed to unknown
       
   207 local-parts within that domain. Those catch-all aliases hence "catch all" mail
       
   208 to any address in the domain (unless a more specific alias, mailbox or
       
   209 relocated entry exists)."""),
       
   210 _(u"""WARNING: Catch-all addresses can cause mail server flooding because
       
   211 spammers like to deliver mail to all possible combinations of names, e.g.
       
   212 to all addresses between abba@example.org and zztop@example.org."""),),
       
   213     # catchallinfo
       
   214     'catchallinfo': (_(u"""This subcommand displays information about catch-all
       
   215 aliases defined for the domain <fqdn>."""),),
       
   216     # catchalldelete
       
   217     'catchalldelete': (_(u"""With this subcommand, catch-all aliases defined
       
   218 for a domain can be removed, either all of them, or a single one if specified
       
   219 explicitly."""),),
       
   220 }
       
   221 
       
   222 del _