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 fs dependency #252

Open
pguardiario opened this issue Mar 20, 2023 · 3 comments
Open

remove fs dependency #252

pguardiario opened this issue Mar 20, 2023 · 3 comments

Comments

@pguardiario
Copy link

Is there any way to remove the fs dependency for serverless?
If not can someone recommend another package / workaround?

@trim21
Copy link

trim21 commented Aug 9, 2024

I'm trying to use nodejs new new single executable application feature and get stuck on this package.

Don't know if it's possble to have a pure js version of this package, so we can use a bundle (for example, esbuild) and pack it in to single executable file without too much complexity.

for example, convert all dat file to base64 and storage them in js as default data source.

A thought would be, convert content of geoip-country.dat and geoip-country6.dat to base64 and use then as default, instead of try to find them on fs.

@bluesmoon
Copy link
Collaborator

The maxmind license prohibits distribution of the data files. It is mandatory for the end user to install it using their own license key.

@trim21
Copy link

trim21 commented Aug 10, 2024

thanks. I just find that official sdk https://github.com/maxmind/GeoIP2-node support passing a buffer directly without requirement of fs.

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

No branches or pull requests

3 participants