Make it easy to use with a private maven repository
@kay-schecker y travaille déjà.
Depuis le 16/10/2024.
Évaluation
Cette issue n'a pas encore été évaluée.
Description
Hello,
I am using the openapi-generator-cli 2.14.0 with a private maven repository (requiring authentication).
Atm using this cli with this setup involves a few steps and makes it feel a bit quirky.
I was wondering if it's possible make the whole process smoother:
- fix NO_PROXY handling
- easier authentication to private maven repositories (no credentials hardcoded in the openapitools.json)
Steps to follow to use the openapi-generator-cli with a private maven repository
Here are the steps I needed to follow to make the openapi-generator-cli work in my corporate environment.
Please note: I am used to have HTTP_PROXY, HTTPS_PROXY and NO_PROXY environment vars setup.
The NO_PROXY is set in order to avoid internal http calls to be sent via the proxy.
-
First run: I get a 503 (returned by my http proxy)
Ok, this is the issue https://github.com/OpenAPITools/openapi-generator-cli/issues/652
Fix: I remove all HTTP_PROXY, HTTPS_PROXY -
Second run: I get a unable to get local issuer certificate.
Ok, this is related to https://github.com/OpenAPITools/openapi-generator-cli/issues/130#issuecomment-737277129
Fix: I add NODE_TLS_REJECT_UNAUTHORIZED=0 as environment variable -
Third run: Request failed with status code 401 (returned by my private maven repository)
Fix: I hardcode my user/pwd credentials in my openapitools.json.
I am not too happy with this solution since I'll need to do some pre-processing to be able to others dev in my team to use their credentials (or for the ci to run):{ "$schema": "./node_modules/@openapitools/openapi-generator-cli/config.schema.json", "spaces": 2, "generator-cli": { "version": "7.9.0", "repository": { "downloadUrl": "https://myuser:mypassword@my.corporate.maven.repo.com/repository/mvn-proxy-group/${groupId}/${artifactId}/${versionName}/${artifactId}-${versionName}.jar" } } }
- Langage dominant
- TypeScript
- Étoiles
- 2k
- Forks
- 208
- Merge moyen
- 7 h 12 min
- PR mergées (30 j)
- 6
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de OpenAPITools/openapi-generator-cli
-
[FEATURE] consider using caret ranges instead of pinned exact versions for runtime dependencies Ouverte
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
-
bug
OpenAPITools/openapi-generator-cli#1213 · 1 personne assignée ·
-
bug
OpenAPITools/openapi-generator-cli#1190 · 1 personne assignée ·
-
bug
OpenAPITools/openapi-generator-cli#1138 · 1 commentaire · 1 personne assignée ·
-
bug
OpenAPITools/openapi-generator-cli#1094 · 1 commentaire · 1 personne assignée ·
Toutes les issues de OpenAPITools/openapi-generator-cli
Issues similaires
-
clawsweeper:fix-shape-clear clawsweeper:queueable-fix clawsweeper:source-repro impact:ux-friction issue-rating: 🦞 diamond lobster no-stale P3
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Difficulté 1/5 Moins d'une heure Accessibilité débutants 76/100
-
code-quality refactoring
Difficulté 2/5 1-3 heures Accessibilité débutants 84/100
github/gh-aw-firewall#8816 ·
-
integration:quickjs org:external priority:backlog topic:code-interpreter topic:middleware type:feature
Difficulté 2/5 1-3 heures Accessibilité débutants 74/100
langchain-ai/deepagents#6450 ·
-
Difficulté 1/5 Moins d'une heure Accessibilité débutants 88/100
vercel/react-tweet#225 ·