knife-ec-backup 1.1.5 → 1.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +0 -4
- data/lib/chef/knife/ec_restore.rb +3 -3
- data/lib/knife_ec_backup/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b1fa04532a43b013c1d7e6f535f6245959c34b88
|
4
|
+
data.tar.gz: 219c74741df411d3072e0927259337972ce69b7e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c85f85e6984ee20d7d87471ff5926df00ae82b834dd8a31242d0ac11e8e44b3bc174090c45676230a2d1005b78e87221223fda79d89e655e7394ede761d829c1
|
7
|
+
data.tar.gz: e2c99033987ecf7e5040c529a0f509b17efc5141d889962537eca3160a3927347d11bf468b4183c9edb52111141a2ee529ce0c6aab755594351a369b2c347f2a
|
data/README.md
CHANGED
@@ -37,8 +37,6 @@ It is recommended that you run this from a frontend Enterprise Chef Server, you
|
|
37
37
|
|
38
38
|
*Options*
|
39
39
|
|
40
|
-
* `--concurrency`:
|
41
|
-
Maximum number of simultaneous requests to send (default: 10)
|
42
40
|
* `--webui-key`:
|
43
41
|
Used to set the path to the WebUI Key (default: /etc/opscode/webui_priv.pem)
|
44
42
|
* `--skip-useracl`:
|
@@ -102,8 +100,6 @@ This compares very closely with the "knife download /" from an OSC server:
|
|
102
100
|
|
103
101
|
*Options*
|
104
102
|
|
105
|
-
* `--concurrency`:
|
106
|
-
Maximum number of simultaneous requests to send (default: 10)
|
107
103
|
* `--webui-key`:
|
108
104
|
Used to set the path to the WebUI Key (default: /etc/opscode/webui_priv.pem)
|
109
105
|
* `--overwrite-pivotal`:
|
@@ -164,7 +164,7 @@ class Chef
|
|
164
164
|
|
165
165
|
# Restore open invitations
|
166
166
|
invitations = JSONCompat.from_json(IO.read("#{dest_dir}/organizations/#{name}/invitations.json"))
|
167
|
-
|
167
|
+
invitations.each do |invitation|
|
168
168
|
begin
|
169
169
|
rest.post_rest("organizations/#{name}/association_requests", { 'user' => invitation['username'] })
|
170
170
|
rescue Net::HTTPServerException => e
|
@@ -176,7 +176,7 @@ class Chef
|
|
176
176
|
|
177
177
|
# Repopulate org members
|
178
178
|
members = JSONCompat.from_json(IO.read("#{dest_dir}/organizations/#{name}/members.json"))
|
179
|
-
|
179
|
+
members.each do |member|
|
180
180
|
username = member['user']['username']
|
181
181
|
begin
|
182
182
|
response = rest.post_rest("organizations/#{name}/association_requests", { 'user' => username })
|
@@ -249,7 +249,7 @@ class Chef
|
|
249
249
|
rest = Chef::REST.new(Chef::Config.chef_server_url)
|
250
250
|
org_admins = rest.get_rest('groups/admins')['users']
|
251
251
|
org_members = rest.get_rest('users').map { |user| user['user']['username'] }
|
252
|
-
org_admins.delete_if { |user| !org_members.include?(user) }
|
252
|
+
org_admins.delete_if { |user| !org_members.include?(user) || user == 'pivotal' }
|
253
253
|
if org_admins[0] != nil
|
254
254
|
# Using an org admin already on the destination server
|
255
255
|
Chef::Config.node_name = org_admins[0]
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: knife-ec-backup
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Keiser
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-01-
|
11
|
+
date: 2014-01-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|