1

I need to be able to install the carto module on an offline server. Is there a way that I could package up carto with all of its dependencies, and install it on a server that has no connection to the internet. The server won't have an initial connection, and will have npm and node installed from a .deb archive.

I've tried using npm-offline, as well as npm-offline-packer. These both require that I have an npm registry or a node project.

I'm hoping to have a start script that can run the required commands and get all packages installed. So far, I'm able to install all ubuntu software, just stuck on node.

asked Feb 13, 2019 at 15:53

1 Answer 1

3

An alternative would be installing it in another machine and copying the package(s) you want inside npm's global node_modules.

npm config get prefix

Gets the path to where it is installed. node_modules are usually under lib/ folder. Module executables could be located under bin/. Having both should be enough to use your global module in another machine.

Since you're looking for a start script the steps you need are:

  1. Getting npm prefix via npm config get prefix
  2. Go to that path
  3. Copy executables you want under bin/ i.e. carto@
  4. Copy content you want from lib/node_modules i.e. lib/node_modules/carto
  5. Apply to the machine you want using the same steps described here
answered Feb 13, 2019 at 17:00
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.