import-meta-env icon indicating copy to clipboard operation
import-meta-env copied to clipboard

Alternatives for building in air-gapped (offline) environment.

Open bayu01 opened this issue 9 months ago • 2 comments

The Issue: the NPM pkg utility is no longer maintained. I struggled finding ways to "package" inside an offline (air-gapped) environment. By default pkg reaches out to the internet (npm registry). It would be a very tedious process bringing binaries for PKG_CACHE_PATH to build offline.

The Workaround: Resort to a shell script that is able to work offline on an nginx-alpine that performs sed -i "s|\"import_meta_env_placeholder\"|\"$json_object\"|g" ./index.html instead.

Suggested Feature: Is it possible to use Node SEA (Node 21+) to build the executable in an offline environment instead?

bayu01 avatar May 13 '24 18:05 bayu01