Export command error: getaddrinfo EAI_AGAIN null
See original GitHub issuePlease do not report security vulnerabilities here. The Responsible Disclosure Program details the procedure for disclosing security issues.
Thank you in advance for helping us to improve this library! Please read through the template below and answer all relevant questions. Your additional work here is greatly appreciated and will help us respond as quickly as possible. For general support or usage questions, use the Auth0 Community or Auth0 Support. Finally, to avoid duplicates, please search existing Issues before submitting one here.
By submitting an Issue to this repository, you agree to the terms within the Auth0 Code of Conduct.
Description
When executing:
a0deploy export --debug --format directory --config_file config.json --output_folder .
I get the error:
2022-05-04T16:17:51.079Z - error: Problem running command export
2022-05-04T16:17:51.080Z - error: getaddrinfo EAI_AGAIN null
N.B.: What’s really strange is that, with the exact same configuration, the import command works perfectly!
Reproduction
- created
config.json
as explained at Configure the Deploy CLI Tool - run
a0deploy export --debug --format directory --config_file config.json --output_folder .
- get the error
Environment
- Version of this library used: 7.3.7
- Version of the platform or framework used, if applicable:
- Other relevant versions (language, server software, OS, browser): Ubuntu 20.04.4 LTS 64 bit
- Other modules/plugins/libraries that might be involved:
Issue Analytics
- State:
- Created a year ago
- Comments:5 (3 by maintainers)
@Luca8991 Thanks for opening this ticket. I can understand how you triggered this bug and would like to prevent it from happening to other folks in the future. We’re in the process of revamping our documentation so my hope is to make it more clear about how to inject environment variables and leverage the keyword mappings. However, because you were able to resolve this ticket and there are no other action items, I’m opting to close this ticket.
Ok great I’m glad you figured it out. If you intend to pass in environment variables for the authentication details, I advise you to explicitly enable that with the
--env=true
flag for both import and export. You also do not need to create the environment variable mapping in theconfig.json
file. Instead, you can omit entirely and the tool will automatically apply those environment variables. Example:config.json
This is because the env flag defaults to true for the import command whereas it defaults to false for export. I know it sounds absurd, but this was just the result of maintaining backwards compatibility and poor forward thinking. I intend to solve this in the next major release, but no timetable on that.