Skip to content

Instantly share code, notes, and snippets.

@nexdrew
Last active September 19, 2016 17:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nexdrew/812f868fe257113aa4a7f6c0f1950026 to your computer and use it in GitHub Desktop.
Save nexdrew/812f868fe257113aa4a7f6c0f1950026 to your computer and use it in GitHub Desktop.
Install npm Enterprise as a virtual appliance

Open Virtualization Format

npm Enterprise can now be installed as a virtual appliance conforming to the Open Virtualization Format. If you already use a hypervisor or virtualization platform for your infrastructure (such as VMware), you can import and run an instance of this virtual appliance as a host VM instead of installing npm Enterprise on one of your existing hosts.

The appliance is distributed as an .ova file, which is essentially a tarball containing a virtual machine template (.ovf file), a virtual hard drive (.vmdk file), and a manifest (.mf file). Download the virtual appliance here.

Once you have downloaded the virtual appliance, check for binary completeness by comparing a SHA256 checksum of your download against the respective checksum file listed.

Virtual Appliance Default Specs

You can adjust the hardware configuration for the virtual machine once it is imported, but the default specs listed here (which ship with the virtual appliance) represent the minimum values you should use.

  • 8 GB memory
  • 2 CPUs
  • 16 GB root storage
  • 100 GB additional storage (not defined by the virtual appliance)

Note that, in addition to the root storage (which may be increased but not decreased), you should attach another virtual disk of at least 100 GB to be used for registry data.

The default network configuration uses Bridged mode so that each VM instance runs as a separate host on your network. This may be altered to conform to your standard network ops.

Installing the Virtual Appliance

  1. Upload/import the .ova into your virtualization platform
  2. Accept the npm Enterprise terms of use if prompted
  3. If the import fails initially, try again with relaxed OVF 1.0 specs
  4. Attach additional storage and customize/increase hardware settings
  5. Run the virtual machine

Note that you can safely ignore any warnings about a missing IDE device, which was used to install the OS when building the virtual appliance.

Initial VM Setup

  1. Login as the default user with username centos and password centos

  2. Reset the default user's password via passwd

  3. Set the hostname to your liking, if you have not done so already, via:

    hostnamectl set-hostname <new_hostname_here>
    
  4. Make sure the Replicated service is running:

    sudo systemctl status replicated
    

    If the status is not "active (running)", reset its configuration and restart the service:

    sudo sh /etc/replicated-bootstrap/reset-config.sh
    sudo systemctl restart replicated replicated-operator
    

Note that any time the IP address of your VM changes, you may need to rerun step 4.

Admin Console Setup

The last step to get npm Enterprise fully configured and running is to set up the admin console, which will include entering your license information. Use the server configuration guide or the steps below to complete initial setup.

  1. Open your favorite web browser and access the admin console on port 8800 of your host

  2. Bypass the TLS warning (the admin console uses a self-signed cert by default)

  3. Choose to either continue using the self-signed cert or upload one to the host

  4. Enter your license email and key

  5. Create a password for the admin console

  6. Verify the preflight checklist

  7. Update the base URL for your private npm registry and website, making sure the values you use allow a user to access this host on your network

  8. Update the paths in the Storage section to reflect directories in your attached storage

    For example, if you mounted additional storage at /mnt, then you could create a directory /mnt/npme and change the storage directories from e.g. /usr/local/lib/npme/couchdb to /mnt/npme/couchdb. Update all six configured storage directories.

  9. Adjust any other configuration settings and click Save at the bottom of the page

  10. Go to the Dashboard page to view appliance status

The containers for your npm Enterprise instance will be downloaded and started. Once running, your private npm registry and website are ready to use!

See docs on how to use the npm CLI client to get started using your npm Enterprise instance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment