Skip to content

Commit 13a3df4

Browse files
authored
Merge pull request #7 from chatwork/readme-username-option
Add a detailed description to `sendgrid.username` option
2 parents 972155c + e989a82 commit 13a3df4

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ Flags:
2828
Address to listen on for web interface and telemetry.
2929
--web.disable-exporter-metrics
3030
Exclude metrics about the exporter itself (promhttp_*, process_*, go_*).
31-
--sendgrid.username="" Set SendGrid username
3231
--sendgrid.api-key="secret"
33-
Set SendGrid API key
32+
[Required] Set SendGrid API key
33+
--sendgrid.username="" [Optional] Set SendGrid username as a label for each metrics. This is for identifying multiple SendGrid users metrics.
3434
--log.level=info Only log messages with the given severity or above. One of: [debug, info, warn, error]
3535
--log.format=logfmt Output format of log messages. One of: [logfmt, json]
3636
--version Show application version.

main.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,14 @@ var (
3636
"web.disable-exporter-metrics",
3737
"Exclude metrics about the exporter itself (promhttp_*, process_*, go_*).",
3838
).Envar("DISABLE_EXPORTER_METRICS").Bool()
39-
sendGridUserName = kingpin.Flag(
40-
"sendgrid.username",
41-
"Set SendGrid username",
42-
).Default("").Envar("SENDGRID_USER_NAME").String()
4339
sendGridAPIKey = kingpin.Flag(
4440
"sendgrid.api-key",
45-
"Set SendGrid API key",
41+
"[Required] Set SendGrid API key",
4642
).Default("secret").Envar("SENDGRID_API_KEY").String()
43+
sendGridUserName = kingpin.Flag(
44+
"sendgrid.username",
45+
"[Optional] Set SendGrid username as a label for each metrics. This is for identifying multiple SendGrid users metrics.",
46+
).Default("").Envar("SENDGRID_USER_NAME").String()
4747
)
4848

4949
func main() {

0 commit comments

Comments
 (0)