plesk_kit 2.2.3 → 2.2.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MWFlNGY1Mzk4NDlkNmZjYTgzOWUyNmQ0MjExZTY2YTE0ZDFhOTllZQ==
4
+ NTdjNjMyZGYwYTU4Nzg5ZTVhYmI0ZjU3MzEyMjkzMGY3M2MxZjA1Nw==
5
5
  data.tar.gz: !binary |-
6
- MDI0Y2EyNDJiNTIxZDVjOGI5YWZmNjRjM2M5MDhjNmIyNGM4MDM3NQ==
6
+ ZTcwYmYwMzAxNDZkZGY2YWZjM2M3MGU5MzNjNGY2Zjg0MjFhYzg3ZA==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- OGViYWVjYjA5NmVjNGMzNDE0ZGI0OWJlZWY5ZjlmMGEyODU2YTEwOWI0OWRk
10
- YWU5MDc2MWM3MDkwODkwMjJkNWZiYWU4NWFmMDdmZDQxN2U0MTE2Nzg5MzZi
11
- MGMxOTM0MjI1OGVhN2Y0Y2UwZTUyZjQzNmVjZjI2ODM1YWE0NzQ=
9
+ YzAyY2NiOTU5ZTA0Mjk0ODc3ZGNhMzBmYzViMGJiZjVkMDgyMmU2ZTBlZDZj
10
+ N2UxOGM0YzllY2ZiMmM4YTI4OTU2MGQ1ZTdlMGQ0NjVjZjQxMjQ1OWM0Yjk2
11
+ ZjAxYTJkOGFlMDFiODYxYTkxYTUxMGQ0MTY2ZDYxOWVjYWU4ZTQ=
12
12
  data.tar.gz: !binary |-
13
- MGQ4MTg3OTAyMDJmZjQyM2ZjN2ZiMzVkZDM3ODdlYTI0MzNiNmZkNjMxN2Jk
14
- NzlkZDJmYjE1MzE0MDcxNzIxM2JlOGMzZGMzNzU0MTExMmZmODBkMTFkMWMz
15
- ZjBhYmU3N2IyYmM2MTllYjNlMDNiYjQ4NjVjYjBhODEzNTVhNzg=
13
+ MTkzMzZkMzViYmIwZGU4NWRhMjdjYWYxMDlmNzAwODUxOTQyMzQyMzlkNzc4
14
+ MTA2NGY1YThiNjIzMmYyNWMyZmU4N2ZjMzQ0YTVhZGQ3Y2NmMjcwMTQxNDg5
15
+ MDM1ZjNkODU2MGZhOGZiY2I4NThiYThjNThhNWJjMWMwNjNkMzc=
@@ -19,7 +19,7 @@ module PleskKit
19
19
 
20
20
  def self.pack_and_reset_password account, new_password
21
21
  server = account.server
22
- packet = account.password_reset_pack shell, new_password
22
+ packet = account.password_reset_pack shell, new_password, account
23
23
  response = transportation_for packet, server
24
24
  account.analyse_password_reset response[0]
25
25
  end
@@ -48,14 +48,14 @@ module PleskKit
48
48
  return xml.target!
49
49
  end
50
50
 
51
- def password_reset_pack shell, new_password
51
+ def password_reset_pack shell, new_password, account
52
52
  xml = shell
53
53
  xml.instruct!
54
54
  xml.packet(:version => '1.6.3.5') {
55
55
  xml.customer {
56
56
  xml.set{
57
57
  xml.filter{
58
-
58
+ xml.login(account.login)
59
59
  }
60
60
  xml.values{
61
61
  xml.gen_info{
@@ -0,0 +1,116 @@
1
+ errors = []
2
+
3
+
4
+ Customer.all.each do |c|
5
+ begin
6
+ subscription = c.subscriptions.last.plesk_subscription
7
+ account = (subscription.customer_account_id.present? ? subscription.customer_account : (subscription.reseller_account_id.present? ? subscription.reseller_account : raise(msg="no accounts?")))
8
+ plesk_subscription_identifier = PleskKit::Communicator.get_subscription_id(subscription)
9
+ usage = PleskKit::Communicator.get_subscription_usage(subscription,plesk_subscription_identifier, account.server)
10
+ rescue
11
+ errors << c
12
+ end
13
+ end
14
+
15
+
16
+ errors
17
+
18
+ # results
19
+
20
+
21
+ # 117.55.227.91 root p8p&uvAwrEDr
22
+ # 117.55.227.95 admin vepeKu4ref!5R@*r
23
+ # 117.55.227.80 admin 8TXY8uMZuq
24
+ # 117.55.227.81 admin 2AcFVjTYsj
25
+
26
+
27
+
28
+
29
+ ( # nope
30
+ ["117.55.227.81", Customer id: 8, customer_name: "1", company_name: nil, username: "1025325",
31
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 04:57:06",
32
+ updated_at: "2014-02-10 04:57:06", customer_account_id: 8,
33
+ workflow_state: "provisioned", platform: "windows"],
34
+
35
+ # ["117.55.227.81", Customer id: 9, customer_name: "1001301", company_name: nil, username: "1025563",
36
+ password: nil, pa_account_id: "1001301", created_at: "2014-02-10 04:57:36",
37
+ updated_at: "2014-02-10 04:57:36", customer_account_id: 9,
38
+ workflow_state: "provisioned", platform: "windows"],
39
+ # Nope
40
+ ["117.55.227.81", Customer id: 10, customer_name: "1", company_name: nil, username: "1025500",
41
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 04:58:20",
42
+ updated_at: "2014-02-10 04:58:20", customer_account_id: 10,
43
+ workflow_state: "provisioned", platform: "windows"],
44
+
45
+ ["117.55.227.81", Customer id: 11, customer_name: "1009658", company_name: nil, username: "1025444",
46
+ password: nil, pa_account_id: "1009658", created_at: "2014-02-10 04:59:01",
47
+ updated_at: "2014-02-10 04:59:01", customer_account_id: 11,
48
+ workflow_state: "provisioned", platform: "windows"],
49
+
50
+ # Nope
51
+ ["117.55.227.91", Customer id: 29, customer_name: "1", company_name: nil, username: "1022908",
52
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 05:11:19",
53
+ updated_at: "2014-02-10 05:11:19", customer_account_id: 29,
54
+ workflow_state: "provisioned", platform: "linux"],
55
+ ["117.55.227.81", Customer id: 12, customer_name: "1", company_name: nil, username: "1020920",
56
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 04:59:37",
57
+ updated_at: "2014-02-10 04:59:38", customer_account_id: 12,
58
+ workflow_state: "provisioned", platform: "windows"],
59
+ ["117.55.227.81", Customer id: 13, customer_name: "1", company_name: nil, username: "1025597",
60
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 05:00:13",
61
+ updated_at: "2014-02-10 05:00:13", customer_account_id: 13,
62
+ workflow_state: "provisioned", platform: "windows"],
63
+ ["117.55.227.81", Customer id: 14, customer_name: "1", company_name: nil, username: "1024035",
64
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 05:00:50",
65
+ updated_at: "2014-02-10 05:00:50", customer_account_id: 14,
66
+ workflow_state: "provisioned", platform: "windows"],
67
+ ["117.55.227.95", Customer id: 42, customer_name: "1", company_name: nil, username: "1020655",
68
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 05:20:27",
69
+ updated_at: "2014-02-10 05:20:27", customer_account_id: 42,
70
+ workflow_state: "provisioned", platform: "linux"],
71
+
72
+
73
+ # RuntimeError: 1007: Domain mmcaccounts.com.au already exists.
74
+
75
+ ["117.55.227.81", Customer id: 17, customer_name: "1009693", company_name: nil, username: "1025565",
76
+ password: nil, pa_account_id: "1009693", created_at: "2014-02-10 05:02:30",
77
+ updated_at: "2014-02-10 05:02:31", customer_account_id: 17,
78
+ workflow_state: "provisioned", platform: "windows"],
79
+ #["117.55.227.81", Customer id: 18, customer_name: "1009650", company_name: nil, username: "1025420",
80
+ password: nil, pa_account_id: "1009650", created_at: "2014-02-10 05:03:01",
81
+ updated_at: "2014-02-10 05:03:01", customer_account_id: 18,
82
+ workflow_state: "provisioned", platform: "windows"],
83
+ # RuntimeError: 1019: Do not use quotes, space and national alphabet characters in a password.
84
+ # RuntimeError: 1007: Domain store.training-for-me.cpanel-hosting.com.au already exists.
85
+ ["117.55.227.91", Customer id: 22, customer_name: "1", company_name: nil, username: "1025189",
86
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 05:07:13",
87
+ updated_at: "2014-02-10 05:07:13", customer_account_id: 22,
88
+ workflow_state: "provisioned", platform: "linux"],
89
+
90
+ #RuntimeError: 1019: Do not use quotes, space and national alphabet characters in a password.
91
+ #RuntimeError: 1007: Domain store.qc-technologies.cpanel-hosting.com.au already exists.
92
+
93
+ ["117.55.227.91", Customer id: 24, customer_name: "1", company_name: nil, username: "1025163",
94
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 05:08:22",
95
+ updated_at: "2014-02-10 05:08:22", customer_account_id: 24,
96
+ workflow_state: "provisioned", platform: "linux"],
97
+
98
+
99
+ #RuntimeError: 1007: This alias already exists.
100
+
101
+ ["117.55.227.91", Customer id: 35, customer_name: "1008972", company_name: nil, username: "1021421",
102
+ password: nil, pa_account_id: "1008972", created_at: "2014-02-10 05:16:46",
103
+ updated_at: "2014-02-10 05:16:46", customer_account_id: 35,
104
+ workflow_state: "provisioned", platform: "linux"],
105
+
106
+ #RuntimeError: 1019: Do not use quotes, space and national alphabet characters in a password.
107
+ #RuntimeError: 1007: Domain store.jcpit.cpanel-hosting.com.au already exists.
108
+
109
+ ["117.55.227.95", Customer id: 45, customer_name: "1", company_name: nil, username: "1024770",
110
+ password: nil, pa_account_id: "1", created_at: "2014-02-10 05:21:41",
111
+ updated_at: "2014-02-10 05:21:41", customer_account_id: 45,
112
+ workflow_state: "provisioned", platform: "linux"]
113
+ )
114
+
115
+ # Currently provisioning
116
+ # [Customer id: 46, customer_name: "1009732", company_name: "", username: "1025660", password: "S3U5y&w$", pa_account_id: "1009732", created_at: "2014-02-10 10:44:34", updated_at: "2014-02-10 10:44:34", customer_account_id: nil, workflow_state: "provisioning", platform: "windows"]
@@ -1,3 +1,3 @@
1
1
  module PleskKit
2
- VERSION = "2.2.3"
2
+ VERSION = "2.2.4"
3
3
  end
@@ -16,7 +16,7 @@ ActiveRecord::Schema.define(:version => 20130925230905) do
16
16
  create_table "plesk_kit_customer_accounts", :force => true do |t|
17
17
  t.string "cname"
18
18
  t.string "pname"
19
- t.string "login"
19
+ t.string "login" #
20
20
  t.string "passwd"
21
21
  t.integer "server_id"
22
22
  t.datetime "created_at", :null => false
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: plesk_kit
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.3
4
+ version: 2.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dionne Saunders
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-02-10 00:00:00.000000000 Z
11
+ date: 2014-02-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -75,6 +75,7 @@ files:
75
75
  - app/models/plesk_kit/server.rb
76
76
  - app/models/plesk_kit/service_plan.rb
77
77
  - app/models/plesk_kit/subscription.rb
78
+ - app/models/plesk_kit/test_audit_manual.rb
78
79
  - app/views/layouts/plesk_kit/application.html.erb
79
80
  - app/views/plesk_kit/customer_accounts/_form.html.erb
80
81
  - app/views/plesk_kit/customer_accounts/edit.html.erb