Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove --tag-prefix from install script to enable overwriting of binary_host #248

Closed
skyd0me opened this issue Jan 28, 2022 · 1 comment
Closed

Comments

@skyd0me
Copy link

skyd0me commented Jan 28, 2022

Hi,

we are using the node-rfc lib for an internal application where we dont have access to the internet (as already discussed in: #125)
But the manual work with overwriting the host entry and publishing the lib again manually is really time consuming.
So I still try to find a better way to do that.

We already created two separate repos for that in artifactory (npm proxy + github download proxy).

Downloading the npm package is easy as we can set the --registry parameter to the internal artifactory.
But downloading the binaries is a different story.

I saw that its possible to set the binary_host env variable of the prebuild-install lib to overwrite the host entry in your package.json to map it to our internal artifactory.
npm config set node-rfc_binary_host https://artifactory...com/artifactory/github-remote/sap/node-rfc/releases/download

Unfortunately this will result in an download url like that:
prebuild-install http request GET https://artifactory...com/artifactory/github-remote/sap/node-rfc/releases/download/true2.5.1/node-rfc-v2.5.1-napi-v6-linux-x64.tar.gz

Somehow the "v" tag gets replaced with "true".

If I manually remove the --tag-prefix from your install script, everything workes like expected as "v" is the default and gets not replaces by the "true" tag.
"install": "prebuild-install -r napi || cmake-js rebuild",

I was not able so far to figure out where this "true" is coming from neither if there is a way to replace the tag-prefix via env variable.

Do you see any other way to solve this problem or maybe its possible to publish a version without the --tag-prefix parameter?
Would really appreciate your help.

Kind Regards
Markus

@bsrdjan
Copy link
Contributor

bsrdjan commented Mar 22, 2022

Hi Markus,

sorry for the long response time. I tested too and the --tag-prefix seem not to be needed any more.

It will be removed in next release

Kind regards,
Srdjan

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants