Skip to content

Commit bbb7b10

Browse files
committed
fix: support PARCA_BEARER_TOKEN environment variable for BearerToken config
This mirrors the Parca Agent's flags: https://github.com/parca-dev/parca-agent/blob/v0.41.1/flags/flags.go#L325
1 parent 604f94c commit bbb7b10

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,8 @@ Flags:
155155
--profile-share-server="api.pprof.me:443"
156156
gRPC address to send share profile requests to.
157157
--store-address=STRING gRPC address to send profiles and symbols to.
158-
--bearer-token=STRING Bearer token to authenticate with store.
158+
--bearer-token=STRING Bearer token to authenticate with store
159+
($PARCA_BEARER_TOKEN).
159160
--bearer-token-file=STRING
160161
File to read bearer token from to authenticate
161162
with store.

pkg/parca/parca.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ type Flags struct {
120120
ProfileShareServer string `default:"api.pprof.me:443" help:"gRPC address to send share profile requests to."`
121121

122122
StoreAddress string `kong:"help='gRPC address to send profiles and symbols to.'"`
123-
BearerToken string `kong:"help='Bearer token to authenticate with store.'"`
123+
BearerToken string `kong:"help='Bearer token to authenticate with store.',env='PARCA_BEARER_TOKEN'"`
124124
BearerTokenFile string `kong:"help='File to read bearer token from to authenticate with store.'"`
125125
Insecure bool `kong:"help='Send gRPC requests via plaintext instead of TLS.'"`
126126
InsecureSkipVerify bool `kong:"help='Skip TLS certificate verification.'"`

0 commit comments

Comments
 (0)