Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

vagrant-readenv

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vagrant-readenv

  • 0.0.3
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

Vagrant ENV Plugin

This is a Vagrant plugin to load environment variables from .env into ENV. More information on why and how we use this plugin is detailed in this post

Requirements

  • Vagrant 1.7.4 or higher

Installation

Install the lastest version using standard vagrant plugin installation method:

$ vagrant plugin install vagrant-env

To install an older version of the plugin use vagrant plugin install vagrant-env --plugin-version VERSION

Usage

After installing, add your application configuration to your .env file in the root of your project

$ echo BOX_NAME=hashicorp/precise64 > .env

Create a a Vagrantfile that looks like the following, ensure to add config.env.enable and fill in your information where necessary. Check out example for reference

Vagrant.configure("2") do |config|
  config.env.enable # enable the plugin
  config.vm.box = ENV['BOX_NAME']
end

Additionally, You may also add export in front of each line so you can source the file in bash:

export AWS_ACCESS_ID=YOURACCESSIDGOESHERE
export AWS_SECRET_ACCESS_ID=YOURSECRETKEYGOESHERE

Should I commit my .env file?

It is recommended that you store development-only settings in your .env file, and commit it to your repository. Make sure that all your credentials for your development environment are different from your other deployments. This makes it easy for other developers to get started on your project, without compromising your credentials for other environments.

Contributing

  1. Fork it ( https://github.com/gosuri/vagrant-env/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

FAQs

Package last updated on 05 Dec 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc