npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

vagrant-box

v1.7.7

Published

An NPM package that makes it easy to add a vagrant dev box to a project

Downloads

36

Readme

Vagrant Box

A portable environment that can be added to any project

Host Requirements


Software

You will need to have the software listed below present on your system

ℹ️ Run boostrap-hosts.sh to install required software on the host

  • Vagrant ( creating VM )
  • VirtualBox ( Virtualizer )
  • Ansible ( Provision using YAML )

Running on Window Sorry but you will need to manually install the dependencies for the time being. You will also need to install the vagrant-guest_ansible plugin

There are also quite a few gotchas with running in WSL which I will document when I have time

Usage

  1. Install
yarn add --dev vagrant-box
  1. Configure the values.yml file to add your project source and any Ansible playbooks you want to run.
  • The values.yml file is how values are loaded into the environment. Any local values or secrets should be stored in values.override.yml
  • You can have local provisioning files setup by storing them in /local_provision they will not be source controlled so that you can run provisioning specific to your setup
# myproject/values.yml

workspace:
  synced_folders:
    - name: my-project
      src: path/to/my/project
      dest: path/on/the/vm/myproject
  playbooks:
    - name: add dependencies
      playbook: provision/setup-env.yml
      run: always
  1. Add any secrets or local values to values.override.yml
# myproject/values.override.yml

workspace:
    aws:
      enabled: true
      default:
        access_key_id: XXXXX
        secret_access_key: XXXXXX
        region: us-west-2
        output: json
      profiles: 
        - name: dev
          role_arn: XXXXX
        - name: staging
          role_arn: XXXXX
        
  1. Run Vagrant
yarn run vb-up
  1. Connect to the VM
yarn run vb-ssh
vagrant@workspace > ls path/to/my/project

See package.json for shortcut scripts

Why?

Encapsulating your development environment for a projects has many benefits

  • Portability - you don't need to worry about the "works on my machine" situation
  • Version control - You can see the changes with the environment reflected in VC
  • Self documenting - because the various steps that are required to get the environment working are in code, new users can see at a glance what is involved.
  • Easier to maintain - Again because the step is in code you can more easily change it.
  • Time travel - You can easily start from a fresh environment or load snapshots of the environment in various states
  • Avoid dependency conflicts - Avoid weirdness for dependencies that you might not be aware of