This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| action :remove do | |
| search("#{new_resource.data_bag}", "groups:#{new_resource.search_group} AND action:remove") do |rm_user| | |
| user rm_user['id'] do | |
| action :remove | |
| end | |
| end | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| users_manage "developers" do | |
| group_name "developers" | |
| group_id 2001 | |
| action [ :create, :remove3 ] | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| action :remove do | |
| search("#{new_resource.data_bag}", "groups:#{new_resource.search_group} AND action:remove") do |rm_user| | |
| user rm_user['id'] do | |
| action :remove | |
| end | |
| end | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| users_manage "developers" do | |
| group_name "developers" | |
| group_id 2001 | |
| action [ :create, :remove ] | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def initialize(*args) | |
| super | |
| @action = :create | |
| end | |
| action :remove do | |
| search("#{new_resource.data_bag}", "groups:#{new_resource.search_group} AND action:remove") do |rm_user| | |
| user rm_user['id'] do | |
| action :remove | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| chef > require 'psych' | |
| LoadError: no such file to load -- psych | |
| from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require' | |
| from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require' | |
| from (irb):6 | |
| from :0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "name": "LOCAL", | |
| "default_attributes": {}, | |
| "override_attributes": {}, | |
| "json_class": "Chef::Environment", | |
| "description": "Testing environment for locally hosted vms", | |
| "cookbook_versions": {}, | |
| "chef_type": "environment" | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| knife node show DBS28N1TEST | |
| knife node show DBS28N1TEST | |
| Node Name: DBS28N1TEST | |
| Environment: LOCAL | |
| FQDN: ip-10-60-101-24.ec2.internal | |
| IP: 184.73.6.235 | |
| Run List: role[base], role[dbshards_node] | |
| Roles: dbshards_node, base | |
| Recipes: chef-client, users, users::developers, sudo, dbshards | |
| Platform: ubuntu 11.04 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| knife environment show LOCAL -Fj | |
| knife environment show LOCAL -Fj | |
| { | |
| "name": "LOCAL", | |
| "description": "Testing environment for locally hosted vms", | |
| "cookbook_versions": { | |
| "dbshards": "= 0.0.13" | |
| }, | |
| "json_class": "Chef::Environment", | |
| "chef_type": "environment", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # debian packages | |
| %w{gcc libxslt-dev libxml2-dev}.each do |pkg| | |
| package pkg do | |
| action :install | |
| end | |
| end | |
| # gems | |
| gem_hash = { | |
| "nokogiri" => "1.5.5", |
OlderNewer