OpenAPITools / OpenAPITools/openapi-generator
Running openapi-generator-cli onb a closed corporate network with a maven mirror
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 26.8k
- Forks
- 7.7k
- PR merge metrics
- PR metrics pending
Description
Description
I am trying to run the OpenAPI generator CLI using npm but it complains that it cannot reach search.maven.org:
Command I am running in node cmd:
npx @openapitools/openapi-generator-cli generate -i .\fail.oas.yaml -g ruby -o .\temp
Error I am getting:
Unable to query repository, because of: "getaddrinfo ENOTFOUND search.maven.org"
It seems like the tool is trying to access public maven, but I'm on a closed network with no internet. We do have a mirrored of maven which I can access, but how do I tell the tooling to look there instead?
Any help would be massively appreciated!
openapi-generator version
OpenAPI declaration file content or url
Command line used for generation
npx @openapitools/openapi-generator-cli generate -i .\fail.oas.yaml -g ruby -o .\temp
Steps to reproduce
Related issues/PRs
Suggest a fix/enhancement
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the npx @openapitools/openapi-generator-cli generate command in a network without public Maven access, using the fail.oas.yaml input and Ruby generator shown in the issue. Trace how the CLI resolves the generator and queries search.maven.org; done means it can use a configured Maven mirror without contacting the public repository.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, node.js
- Domain
- build-system, cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100