Skip to content

Commit 51917fa

Browse files
committed
Update manpage of mailgw
Fix minor issues (ssl -> tls/ssl), --default-class option with '-' instead of underscore.
1 parent 6f92b44 commit 51917fa

File tree

3 files changed

+69
-47
lines changed

3 files changed

+69
-47
lines changed

doc/user_guide.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -688,7 +688,7 @@ POP:
688688
are both valid.
689689

690690
POPS:
691-
Connect to a POP server over ssl.
691+
Connect to a POP server over tls/ssl.
692692
This supports the same notation as POP::
693693

694694
pops username:password@server
@@ -710,19 +710,19 @@ IMAP:
710710
imap username:password@server mailbox
711711

712712
IMAPS:
713-
Connect to an IMAP server over ssl.
713+
Connect to an IMAP server over tls/ssl.
714714
This supports the same notation as IMAP::
715715

716716
imaps username:password@server [mailbox]
717717

718718
IMAPS_CRAM:
719-
Connect to an IMAP server over ssl using CRAM-MD5 authentication.
719+
Connect to an IMAP server over tls/ssl using CRAM-MD5 authentication.
720720
This supports the same notation as IMAP::
721721

722722
imaps_cram username:password@server [mailbox]
723723

724724
IMAPS_OAUTH:
725-
Connect to an IMAP server over ssl using OAUTH authentication.
725+
Connect to an IMAP server over tls/ssl using OAUTH authentication.
726726
Note that this does not support a password in imaps URLs.
727727
Instead it uses only the user and server and a command-line option for
728728
the directory with the files ``access_token``, ``refresh_token``,

roundup/scripts/roundup_mailgw.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@
9494
are both valid.
9595
9696
POPS:
97-
Connect to a POP server over ssl.
97+
Connect to a POP server over ssl/tls.
9898
This supports the same notation as POP.
9999
100100
APOP:
@@ -110,17 +110,17 @@
110110
imap username:password@server mailbox
111111
112112
IMAPS:
113-
Connect to an IMAP server over ssl.
113+
Connect to an IMAP server over ssl/tls.
114114
This supports the same notation as IMAP.
115115
imaps username:password@server [mailbox]
116116
117117
IMAPS_CRAM:
118-
Connect to an IMAP server over ssl using CRAM-MD5 authentication.
118+
Connect to an IMAP server over ssl/tls using CRAM-MD5 authentication.
119119
This supports the same notation as IMAP.
120120
imaps_cram username:password@server [mailbox]
121121
122122
IMAPS_OAUTH:
123-
Connect to an IMAP server over ssl using OAUTH authentication.
123+
Connect to an IMAP server over ssl/tls using OAUTH authentication.
124124
Note that this does not support a password in imaps URLs.
125125
Instead it uses only the user and server and a command-line option for
126126
the directory with the files 'access_token', 'refresh_token',
@@ -150,7 +150,7 @@ def parse_arguments(argv):
150150
cmd.add_argument('args', nargs='*')
151151
cmd.add_argument('-v', '--version', action='store_true',
152152
help='print version and exit')
153-
cmd.add_argument('-c', '--default_class', default='',
153+
cmd.add_argument('-c', '--default-class', default='',
154154
help="Default class of item to create (else the tracker's "
155155
"MAILGW_DEFAULT_CLASS)")
156156
cmd.add_argument('-O', '--oauth-directory',

share/man/man1/roundup-mailgw.1

Lines changed: 60 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -2,62 +2,70 @@
22
.SH NAME
33
roundup-mailgw \- mail gateway for roundup
44
.SH SYNOPSIS
5-
\fBroundup-mailgw\fP [\fI-v\fP] [\fI-c\fP \fIdefault_class\fP]
6-
[[\fI-C\fP \fIclass\fP] \fI-S\fP \fIfield=value\fP]
5+
\fBroundup-mailgw\fP [\fI-h|--help] [\fI-v\fP] [\fI--version\fP]
6+
[\fI-c|--default-class\fP \fIdefault_class\fP]
7+
[\fI-S|--set-value\fP \fI[class.]field=value\fP]
8+
[\fI-O|--oauth-directory\fP \fIdirectory\fP]
9+
[\fI-T|--oauth-token-endpoint\fP \fIendpoint-url\fP]
710
[\fIinstance_home\fP] [\fImail source [specification]\fP]
811
.SH OPTIONS
912
.TP
10-
\fB-v\fP
13+
\fB-v\fP \fB--version\fP
1114
Print version and exit.
1215
.TP
13-
\fB-c\fP \fIhyperdb class\fP
14-
specify the default tracker class - one of issue (the default), msg, file, user etc. Overrides the
15-
tracker's mailgw default_class setting.
16+
\fB-c\fP \fB--default-class\fP \fIhyperdb class\fP
17+
specify the default tracker class - one of issue (the default), msg,
18+
file, user etc. Overrides the tracker's mailgw \fIdefault_class\fP setting.
1619
.TP
17-
\fB-C\fP \fIhyperdb class\fP
18-
specify a tracker class - one of msg (the default), issue, file, user - to
19-
manipulate with -S options
20+
\fB-S\fP \fB--set-value\fP \fI[class.]property\fP\fB=\fP\fIvalue\fP[\fB;\fP\fIproperty\fP\fB=\fP\fIvalue\fP]
21+
specify the values to set on the class specified as prefix using the same
22+
format as the Subject line property manipulations. If the class prefix
23+
is left out it defaults to \fImsg\fP. Can also be
24+
specified with \fB--set-value\fP (and abbreviated to \fB--set\fP).
2025
.TP
21-
\fB-S\fP \fIproperty\fP\fB=\fP\fIvalue\fP[\fB;\fP\fIproperty\fP\fB=\fP\fIvalue\fP] \fIpairs\fP
22-
specify the values to set on the class specified by \fB-C\fP using the same
23-
format as the Subject line property manipulations. Can also be
24-
specified with \fB--set\fP.
26+
\fB-O\fP \fB--oauth-directory\fP \fIdirectory\fP
27+
Only with OAuth authentication specify the directory containing
28+
additional OAuth credentials.
29+
.TP
30+
\fB-T\fP \fB--oauth-token-endpoint\fP \fIurl\fP
31+
Token endpoint URL of your cloud provider, only used with OAuth.
2532
.SH DESCRIPTION
2633
The roundup mail gateway may be called in one of four ways:
2734
.IP \(bu
2835
without arguments which will use the env var ROUNDUP_INSTANCE,
2936
.IP \(bu
30-
with an instance_home as the only argument,
37+
with an \fIinstance_home\fP as the only argument,
3138
.IP \(bu
32-
with both an instance_home and a mail spool file, or
39+
with both an \fIinstance_home\fP and a mail spool file, or
3340
.IP \(bu
3441
with both an instance home and a mail source type and its specification.
3542
.PP
3643
\fBPIPE\fP
3744
.br
38-
In the first and second cases, the mail gateway reads a single message from the
39-
standard input and submits the message to the roundup.mailgw module.
45+
If there is no mail source specified, the mail gateway reads a single
46+
message from the standard input and submits the message to the
47+
roundup.mailgw module.
4048

4149
\fBUNIX mailbox\fP
4250
.br
43-
In the second case, the gateway reads all messages from the mail spool
51+
In this case, the gateway reads all messages from the UNIX mail spool
4452
file and submits each in turn to the roundup.mailgw module. The file is
4553
emptied once all messages have been successfully handled. The file is
4654
specified as:
47-
\fImailbox /path/to/mailbox\fP
55+
\fBmailbox\fP \fI/path/to/mailbox\fP
4856

49-
In all of the following the username and password can be stored in a
50-
~/.netrc file. In this case only the server name need be specified on
51-
the command-line.
57+
In all of the following mail source types, the username and password
58+
can be stored in a ~/.netrc file. If done so, only the server name
59+
needs to be specified on the command-line.
5260

5361
The username and/or password will be prompted for if not supplied on
5462
the command-line or in ~/.netrc.
5563

5664
\fBPOP\fP
5765
.br
58-
In the third case, the gateway reads all messages from the POP server
59-
specified and submits each in turn to the roundup.mailgw module. The
60-
server is specified as:
66+
For the mail source "pop", the gateway reads all messages from the POP
67+
server specified and submits each in turn to the roundup.mailgw module.
68+
The server is specified as:
6169
\fBpop\fP \fIusername\fP\fB:\fP\fIpassword\fP\fB@\fP\fIserver\fP
6270
.br
6371
The username and password may be omitted:
@@ -68,13 +76,8 @@ are both valid.
6876

6977
\fBPOPS\fP
7078
.br
71-
Connect to the POP server over ssl/tls. This requires python 2.4 or
72-
later. This supports the same notation as POP.
73-
74-
75-
\fBpops\fP \fIusername\fP\fB:\fP\fIpassword\fP\fB@\fP\fIserver\fP
76-
.br
77-
etc.
79+
Connect to the POP server over ssl/tls.
80+
This supports the same notation as POP.
7881

7982
\fBAPOP\fP
8083
.br
@@ -97,13 +100,31 @@ Connect to an IMAP server over ssl/tls.
97100
This supports the same notation as IMAP.
98101
\fBimaps\fP \fIusername\fP\fB:\fP\fIpassword\fP\fB@\fP\fIserver\fP [\fImailbox\fP]
99102

100-
101103
\fBIMAPS_CRAM\fP
102104
.br
103105
Connect to an IMAP server over ssl/tls using CRAM-MD5 authentication.
104106
This supports the same notation as IMAP.
105107
\fBimaps_cram\fP \fIusername\fP\fB:\fP\fIpassword\fP\fB@\fP\fIserver\fP [\fImailbox\fP]
106108

109+
\fBIMAPS_OAUTH\fP
110+
.br
111+
Connect to an IMAP server over ssl/tls using OAUTH authentication.
112+
Note that this does not support a password in imaps URLs.
113+
Instead it uses only the user and server and a command-line option for
114+
the directory with the files \fBaccess_token\fP, \fBrefresh_token\fP,
115+
\fBclient_secret\fP, and \fBclient_id\fP.
116+
By default this directory is \fBoauth\fP in your tracker home directory. The
117+
access token is tried first and, if expired, the refresh token together
118+
with the client secret is used to retrieve a new access token. Note that
119+
both token files need to be \fIwriteable\fP, the access token is
120+
continuously replaced and some cloud providers may also renew the
121+
refresh token from time to time:
122+
\fBimaps_oauth\fP \fIusername\fP\fB@\fP\fIserver\fP [\fImailbox\fP]
123+
.br
124+
The refresh and access tokens (the latter can be left empty), the
125+
client id and the client secret need to be retrieved via cloud provider
126+
specific protocols or websites.
127+
107128
.SH ENVIRONMENT VARIABLES
108129

109130
\fBROUNDUP_INSTANCE\fP
@@ -116,8 +137,8 @@ If your msg class has a messsagetype property you can set
116137
up aliases to receive the different types of messages. Setting up
117138
an alias in your MTA Using:
118139

119-
tracker: |/tools/roundup/bin/roundup-mailgw -C msg
120-
-S "messagetype=reply - to all" /var/roundup/sysadmin
140+
tracker: |/tools/roundup/bin/roundup-mailgw
141+
-S "msg.messagetype=reply - to all" /var/roundup/sysadmin
121142

122143
(the lines are split for readability. In the alias file they will be
123144
on the same line). Replace /tools/roundup/bin/roundup-mailgw by your
@@ -128,8 +149,8 @@ to all". The roundup tracker instance is located at
128149

129150
A comment alias would receive emails at tracker_comment with:
130151

131-
tracker_comment: |/tools/roundup/bin/roundup-mailgw -C msg
132-
-S "messagetype=comment - to technical" /var/roundup/sysadmin
152+
tracker_comment: |/tools/roundup/bin/roundup-mailgw
153+
-S "msg.messagetype=to tech" /var/roundup/sysadmin
133154

134155
which would be a technical message. These messages can trigger
135156
different workflows based on the messagetype.
@@ -144,4 +165,5 @@ This manpage was written by Bastian Kleineidam
144165
The main author of roundup is Richard Jones
145166
146167

147-
Updates by John Rouillard <[email protected]>.
168+
Updates by John Rouillard <[email protected]> and Ralf
169+
Schlatterbeck <[email protected]>.

0 commit comments

Comments
 (0)