Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms

Select Status

RSS

gitlab-vault (1) Versions 0.2.0

Library for working with vault secrets

Policyfile
Berkshelf
Knife
cookbook 'gitlab-vault', '~> 0.2.0', :supermarket
cookbook 'gitlab-vault', '~> 0.2.0'
knife supermarket install gitlab-vault
knife supermarket download gitlab-vault
README
Dependencies
Changelog
Quality 33%

gitlab-vault

Merge node attributes with values from a Chef Vault item at run time.

Usage

Suppose your recipe's attributes are in node['my-cookbook']['my-recipe']. You
want to store some of the attributes in a Chef Vault called 'my-vault' (with
item 'my-item' ) instead of in the node attributes. At the start of your
recipe, write:

include_recipe 'gitlab-vault'
my_recipe_conf = GitLab::Vault.get(node, 'my-cookbook', 'my-recipe')

You now have a hash my_recipe_conf which you can use wherever you would
otherwise write node['my-cookbook']['my-recipe']. At run time, this hash will
contain a mix of regular attributes and secrets.

In the Chef role applied to your nodes that should see the secrets, specify
which vault and vault item to use.

{
  "my-cookbook": {
    "my-recipe": {
      "not_secret": "everybody is allowed to see this",
      "chef_vault": "my-vault",
      "chef_vault_item": "my-item"
    }
}

In your Chef Vault item, you can just mirror the structure of your node
attributes. Note that the 'id' field is used by Chef Vault itself.

{
  "id": "my-item",
  "my-cookbook": {
    "my-recipe": {
      "secret": "need to know only"
    }
  }
}

Then at run time, the my_recipe_conf hash will look like:

{
  "my-cookbook": {
    "my-recipe": {
      "not_secret": "everybody is allowed to see this",
      "secret": "need to know only",
      "chef_vault": "my-vault",
      "chef_vault_item": "my-item"
    }
  }
}

License and Authors

Author:: GitLab Inc. (jacob@gitlab.com, jeroen@gitlab.com)
MIT license

0.2.0

Refactor of gitlab-attributes-with-secrets

0.1.0

Initial release of gitlab-attributes-with-secrets

Collaborator Number Metric
            

0.2.0 failed this metric

Failure: Cookbook has 0 collaborators. A cookbook must have at least 2 collaborators to pass this metric.

Contributing File Metric
            

0.2.0 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file

Foodcritic Metric
            

0.2.0 passed this metric

No Binaries Metric
            

0.2.0 passed this metric

Testing File Metric
            

0.2.0 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file

Version Tag Metric
            

0.2.0 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number