Dynatrace/dynatrace-configuration-as-code

ERROR error retrieving token for enviroment

Closed this issue · 1 comments

Describe the bug
using the new CLI when I try to download a configuration I get

ERROR error retrieving token for enviroment production environment variable ***** not found

How to reproduce
Steps to reproduce the behavior:

run
monaco download --downloadSpecificAPI application-web -e=environments.yaml

Expected behavior
to download the application-web configurations

Log output

2021-11-23 18:17:48 DEBUG request log not activated
2021-11-23 18:17:48 DEBUG response log not activated
2021-11-23 18:17:48 INFO  Dynatrace Monitoring as Code v1.6.0
2021-11-23 18:17:48 INFO  Creating base project name production
2021-11-23 18:17:48 ERROR error retrieving token for enviroment production environment variable ******** not found
2021-11-23 18:17:48 ERROR error while downloading configs for environment production %!v(MISSING)

Environment (please complete the following information):

  • OS: [macOs Catalina 10.15.7]
  • Tool version [e.g. 1.6.0]

Additional context
I'm using this yaml

production:
    - name: "production"
    - env-url: "****"
    - env-token-name: "*****"

the token is the DT token and has configuration API read and write permissions

After reading the source code I found that you are actually looking for an local environment variable which was not clear from the documentation