mapbox-gl-native icon indicating copy to clipboard operation
mapbox-gl-native copied to clipboard

libEGL.so not found running inside AWS Lambda

Open CheeseNPort opened this issue 4 years ago • 3 comments

I am trying to run mapbox-native-gl on a nodeJs application inside AWS lambda. But this can also be reproduced by creating a node application, installing the mapbox-native-gl NPM package and writing simple code to render a map and then deploying onto an amazonlinux box.

Error: libEGL.so.1: cannot open shared object file: No such file or directory at Object.Module._extensions..node (internal/modules/cjs/loader.js:807:18) at Module.load (internal/modules/cjs/loader.js:653:32) at tryModuleLoad (internal/modules/cjs/loader.js:593:12) at Function.Module._load (internal/modules/cjs/loader.js:585:3) at Module.require (internal/modules/cjs/loader.js:692:17) at require (internal/modules/cjs/helpers.js:25:18) at Object. (/print/iventis_map_print_service/print-service-lambda/node_modules/@mapbox/mapbox-gl-native/platform/node/index.js:5:12) at Module._compile (internal/modules/cjs/loader.js:778:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10) at Module.load (internal/modules/cjs/loader.js:653:32)

I wondered if the package had to be compiled specifically for this version of linux, but thought that the node package should work anyway. Even so, I gave it a go but the instructions given at https://github.com/mapbox/mapbox-gl-native/tree/master/platform/linux do not work on amazonlinux because it does not support apt-get.

CheeseNPort avatar Apr 24 '20 10:04 CheeseNPort

@CheeseNPort do these amazonlinux instances have a GPU?

tobrun avatar Apr 28 '20 06:04 tobrun

@tobrun I do not believe the functions have access to the GPU.

CheeseNPort avatar Apr 28 '20 08:04 CheeseNPort

The same problem

tileserver-gl/node_modules/@mapbox/mapbox-gl-native/platform/node/index.js:1 Error: libEGL.so.1: cannot open shared object file: No such file or directory at Object.Module._extensions..node (internal/modules/cjs/loader.js:807:18)

KushnirDV avatar Jun 24 '21 12:06 KushnirDV