I have the exact same error which says
at bindings (/node_modules/pg-native/node_modules/libpq/node_modules/bindings/bindings.js:76:44)
This might seem similar to:
Error: Module did not self-register.
but the difference being, I am using docker to build images, so it will not be possible for me to go back and remove node_modules and perform npm install again for every container.
Is there a more elegant solution?