No commit activity in last 3 years
No release in over 3 years
If you manage your AWS credentials via different profiles on default aws-cli, this plugin will allow you to use these credentials on you Vagrantfile.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.11
~> 10.0
~> 3.0

Runtime

 Project Readme

Vagrant Aws Credentials

This plugin allows Vagrant to read your AWS Credentials, just configure which AWS profile to use. It serves as an alternative while this pull request* isn't merged to vagrant-aws plugin.

*The pull request above was merged. This plugin isn't need anymore, yay \o/ Check vagrant-aws plugin Quickstart session for instructions on how to configure this same feature on it.

I'm mainly keeping this project here to serve as reference to myself on how to develop vagrant plugins.

Installation

$ vagrant plugin install vagrant-aws-credentials

Usage

Get your AWS Credentials on the standard awscli credentials file. Tell vagrant-aws-credentials plugin which profile you're gonna use:

config.aws_credentials.profile = "default"

Config your vagrant-aws plugin on the Vagrantfile to search for secrets on the following environment variables:

  config.aws_credentials.profile = "default"
  config.vm.provider :aws do |aws, override|

    aws.access_key_id             = ENV["VAGRANT_AWS_ACCESS_KEY"]
    aws.secret_access_key         = ENV["VAGRANT_AWS_SECRET_ACCESS_KEY"]
    aws.session_token             = ENV["VAGRANT_AWS_SESSION_TOKEN"]
    ...
  end

Development

After checking out the repo, run bin/setup to install dependencies. Then, run rake spec to run the tests. You can also run bin/console for an interactive prompt that will allow you to experiment.

To run this plugin with Vagrant, you need to be aware of plugin development basics.

But a quick tip is to use as:

$ bundle exec vagrant

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/datherra/vagrant-aws-credentials. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The gem is available as open source under the terms of the MIT License.