-
Notifications
You must be signed in to change notification settings - Fork 28
Closed
Description
Describe the bug
Related to #38
The command example parsing is not correct based on example text,
To Reproduce
set the cobra command example to the following code example
Source Code
cmd = &cobra.Command{
Example: `# just issue token
notarycli issue
# issue token without cache
notarycli issue --no-cache
# issue token with specific audience
notarycli issue --audience "arn:service:region::auth:application:handler"
# issue token with custom expiration and claims
notarycli issue --expiration-seconds 3600 --claims "project=myproject" --claims "env=prod"
# issue token with JSON output format
notarycli issue --output-format json
# issue token from system account credentials
SERVICE_USERNAME=<user> SERVICE_PASSWORD=<pwd> \
notarycli issue
# issue token from mTLS certificate identity
AUTH_SYSTEM_ACCOUNT_ENABLED=0 AUTH_SERVICE_ENABLED=0 AUTH_ACTOR_ASSUME_ENABLED=0 \
AUTH_MTLS_CERT_FILE=/path/to/chain.pem AUTH_MTLS_KEY_FILE=/path/to/key.pem \
notarycli issue
# issue OIDC token directly (bypasses Auth Service)
notarycli issue --oidc-token
# issue application token (requires application password)
notarycli issue --token-type application --application-id my-app-id -p
# When prompted, enter: AUTH_APPLICATION_PASSWORD or provide via env var
# issue application token with environment variable
AUTH_APPLICATION_PASSWORD=mypassword \
notarycli issue --token-type application --application-id my-app-id
`,
}
Screenshots
Metadata
Metadata
Assignees
Labels
No labels