joyent-cloud-pricing 2.0.0 → 2.1.0
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/.atom-build.json +12 -0
- data/.travis.yml +1 -1
- data/config/joyent_pricing.yml +343 -170
- data/lib/pricing.rb +1 -1
- data/lib/pricing/analyzer.rb +1 -2
- data/lib/pricing/report.txt.erb +1 -1
- data/lib/pricing/scraper.rb +3 -1
- data/lib/pricing/version.rb +1 -1
- data/lib/tasks/update.rake +5 -4
- data/spec/pricing/configuration_spec.rb +2 -2
- data/spec/pricing/scraper_spec.rb +25 -9
- metadata +4 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b6b6a8c337b3fd2d869b60ee917aa7af293fff82
|
|
4
|
+
data.tar.gz: aa7755fd8059208d0049177a24ef1d865b1427ea
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d55f5be23440532b21cd00a35659f30091deb169acc55783899a470d2c418ec219f484ff1971254a0dc9f13cb4a664626dbc7ea1ce4337f38cf2179d58d5a343
|
|
7
|
+
data.tar.gz: fe42f6d624729d8f2e0d60673aff18fd7ba5db9b6bbe09a100b1b199fb4e7beb5e8644874b0a506a26b4148e90fa3386839c9eadf7970467ebdf2ee5417e8fc9
|
data/.atom-build.json
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"cmd": "bundle exec rspec",
|
|
3
|
+
"name": "All Specs",
|
|
4
|
+
"errorMatch": [
|
|
5
|
+
"^regexp1$",
|
|
6
|
+
"^regexp2$"
|
|
7
|
+
],
|
|
8
|
+
"env": {
|
|
9
|
+
"PATH": "/usr/local/opt/rbenv/shims:/usr/local/opt/rbenv/bin:/Users/kig/.rbenv/shims:/Users/kig/.pyenv/shims:/Users/kig/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/kig/workspace/kigster/pullulant"
|
|
10
|
+
},
|
|
11
|
+
"keymap": "ctrl-r"
|
|
12
|
+
}
|
data/.travis.yml
CHANGED
data/config/joyent_pricing.yml
CHANGED
|
@@ -1,275 +1,184 @@
|
|
|
1
1
|
---
|
|
2
|
-
:date: '
|
|
2
|
+
:date: '2016-02-14 01:23:52 -0800'
|
|
3
3
|
:pricing:
|
|
4
|
-
:
|
|
5
|
-
:name:
|
|
4
|
+
:g3-standard-0.625-smartos:
|
|
5
|
+
:name: g3-standard-0.625-smartos
|
|
6
6
|
:os: SmartOS
|
|
7
|
-
:cost: 0.
|
|
8
|
-
:cpus: 0.
|
|
9
|
-
:disk:
|
|
10
|
-
:ram: 0.
|
|
11
|
-
:
|
|
12
|
-
:name:
|
|
7
|
+
:cost: 0.02
|
|
8
|
+
:cpus: 0.15
|
|
9
|
+
:disk: 20
|
|
10
|
+
:ram: 0.625
|
|
11
|
+
:g3-standard-1.75-smartos:
|
|
12
|
+
:name: g3-standard-1.75-smartos
|
|
13
13
|
:os: SmartOS
|
|
14
|
-
:cost: 0.
|
|
15
|
-
:cpus: 0
|
|
16
|
-
:disk:
|
|
17
|
-
:ram:
|
|
18
|
-
:
|
|
19
|
-
:name:
|
|
14
|
+
:cost: 0.056
|
|
15
|
+
:cpus: 1.0
|
|
16
|
+
:disk: 56
|
|
17
|
+
:ram: 1.75
|
|
18
|
+
:g3-standard-3.75-smartos:
|
|
19
|
+
:name: g3-standard-3.75-smartos
|
|
20
20
|
:os: SmartOS
|
|
21
|
-
:cost: 0.
|
|
22
|
-
:cpus: 0.25
|
|
23
|
-
:disk: 12
|
|
24
|
-
:ram: 0.512
|
|
25
|
-
:t4-standard-1G:
|
|
26
|
-
:name: t4-standard-1G
|
|
27
|
-
:os: Windows Enterprise
|
|
28
|
-
:cost: 0.226
|
|
29
|
-
:cpus: 0.5
|
|
30
|
-
:disk: 25
|
|
31
|
-
:ram: 1.0
|
|
32
|
-
:t4-standard-2G:
|
|
33
|
-
:name: t4-standard-2G
|
|
34
|
-
:os: Windows Enterprise
|
|
35
|
-
:cost: 0.253
|
|
21
|
+
:cost: 0.12
|
|
36
22
|
:cpus: 1.0
|
|
37
|
-
:disk:
|
|
38
|
-
:ram:
|
|
39
|
-
:
|
|
40
|
-
:name:
|
|
41
|
-
:os:
|
|
42
|
-
:cost: 0.
|
|
23
|
+
:disk: 123
|
|
24
|
+
:ram: 3.75
|
|
25
|
+
:g3-standard-7.5-smartos:
|
|
26
|
+
:name: g3-standard-7.5-smartos
|
|
27
|
+
:os: SmartOS
|
|
28
|
+
:cost: 0.24
|
|
43
29
|
:cpus: 2.0
|
|
44
|
-
:disk:
|
|
45
|
-
:ram:
|
|
46
|
-
:
|
|
47
|
-
:name:
|
|
30
|
+
:disk: 738
|
|
31
|
+
:ram: 7.5
|
|
32
|
+
:g3-standard-15-smartos:
|
|
33
|
+
:name: g3-standard-15-smartos
|
|
48
34
|
:os: SmartOS
|
|
49
|
-
:cost: 0.
|
|
35
|
+
:cost: 0.48
|
|
50
36
|
:cpus: 4.0
|
|
51
|
-
:disk:
|
|
52
|
-
:ram:
|
|
53
|
-
:
|
|
54
|
-
:name:
|
|
37
|
+
:disk: 1467
|
|
38
|
+
:ram: 15.0
|
|
39
|
+
:g3-standard-30-smartos:
|
|
40
|
+
:name: g3-standard-30-smartos
|
|
55
41
|
:os: SmartOS
|
|
56
|
-
:cost: 0.
|
|
42
|
+
:cost: 0.96
|
|
57
43
|
:cpus: 8.0
|
|
58
|
-
:disk:
|
|
59
|
-
:ram:
|
|
60
|
-
:
|
|
61
|
-
:name:
|
|
44
|
+
:disk: 1683
|
|
45
|
+
:ram: 30.0
|
|
46
|
+
:g3-standard-48-smartos:
|
|
47
|
+
:name: g3-standard-48-smartos
|
|
62
48
|
:os: SmartOS
|
|
63
|
-
:cost:
|
|
49
|
+
:cost: 1.536
|
|
50
|
+
:cpus: 12.0
|
|
51
|
+
:disk: 1683
|
|
52
|
+
:ram: 48.0
|
|
53
|
+
:g3-standard-64-smartos:
|
|
54
|
+
:name: g3-standard-64-smartos
|
|
55
|
+
:os: SmartOS
|
|
56
|
+
:cost: 2.048
|
|
64
57
|
:cpus: 16.0
|
|
65
|
-
:disk:
|
|
66
|
-
:ram: 32.0
|
|
67
|
-
:t4-standard-64G:
|
|
68
|
-
:name: t4-standard-64G
|
|
69
|
-
:os: Windows Standard
|
|
70
|
-
:cost: 1.74
|
|
71
|
-
:cpus: 32.0
|
|
72
|
-
:disk: 1600
|
|
58
|
+
:disk: 2100
|
|
73
59
|
:ram: 64.0
|
|
74
|
-
:
|
|
75
|
-
:name:
|
|
76
|
-
:os:
|
|
77
|
-
:cost: 2.
|
|
78
|
-
:cpus:
|
|
79
|
-
:disk:
|
|
60
|
+
:g3-standard-80-smartos:
|
|
61
|
+
:name: g3-standard-80-smartos
|
|
62
|
+
:os: SmartOS
|
|
63
|
+
:cost: 2.56
|
|
64
|
+
:cpus: 20.0
|
|
65
|
+
:disk: 2625
|
|
66
|
+
:ram: 80.0
|
|
67
|
+
:g3-standard-96-smartos:
|
|
68
|
+
:name: g3-standard-96-smartos
|
|
69
|
+
:os: SmartOS
|
|
70
|
+
:cost: 3.072
|
|
71
|
+
:cpus: 24.0
|
|
72
|
+
:disk: 3150
|
|
80
73
|
:ram: 96.0
|
|
81
|
-
:
|
|
82
|
-
:name:
|
|
83
|
-
:os: Windows Enterprise
|
|
84
|
-
:cost: 3.56
|
|
85
|
-
:cpus: 64.0
|
|
86
|
-
:disk: 3100
|
|
87
|
-
:ram: 128.0
|
|
88
|
-
:t4-standard-160G:
|
|
89
|
-
:name: t4-standard-160G
|
|
90
|
-
:os: Windows Enterprise
|
|
91
|
-
:cost: 4.4
|
|
92
|
-
:cpus: 80.0
|
|
93
|
-
:disk: 3900
|
|
94
|
-
:ram: 160.0
|
|
95
|
-
:t4-standard-196G:
|
|
96
|
-
:name: t4-standard-196G
|
|
97
|
-
:os: Windows Enterprise
|
|
98
|
-
:cost: 5.24
|
|
99
|
-
:cpus: 96.0
|
|
100
|
-
:disk: 4700
|
|
101
|
-
:ram: 196.0
|
|
102
|
-
:t4-standard-224G:
|
|
103
|
-
:name: t4-standard-224G
|
|
74
|
+
:g3-standard-128-smartos-cc:
|
|
75
|
+
:name: g3-standard-128-smartos-cc
|
|
104
76
|
:os: SmartOS
|
|
105
|
-
:cost:
|
|
106
|
-
:cpus:
|
|
107
|
-
:disk:
|
|
108
|
-
:ram:
|
|
109
|
-
:g3-highmemory-17.125-kvm:
|
|
110
|
-
:name: g3-highmemory-17.125-kvm
|
|
111
|
-
:os: Linux
|
|
112
|
-
:cost: 0.409
|
|
113
|
-
:cpus: 2.0
|
|
114
|
-
:disk: 420
|
|
115
|
-
:ram: 17.13
|
|
116
|
-
:g3-highmemory-34.25-kvm:
|
|
117
|
-
:name: g3-highmemory-34.25-kvm
|
|
118
|
-
:os: Linux
|
|
119
|
-
:cost: 0.817
|
|
120
|
-
:cpus: 4.0
|
|
121
|
-
:disk: 843
|
|
122
|
-
:ram: 34.25
|
|
123
|
-
:g3-highmemory-68.375-kvm:
|
|
124
|
-
:name: g3-highmemory-68.375-kvm
|
|
125
|
-
:os: Linux
|
|
126
|
-
:cost: 1.63
|
|
127
|
-
:cpus: 8.0
|
|
128
|
-
:disk: 1122
|
|
129
|
-
:ram: 68.38
|
|
130
|
-
:g3-highcpu-1.75-kvm:
|
|
131
|
-
:name: g3-highcpu-1.75-kvm
|
|
132
|
-
:os: Linux
|
|
133
|
-
:cost: 0.127
|
|
134
|
-
:cpus: 2.0
|
|
135
|
-
:disk: 75
|
|
136
|
-
:ram: 1.75
|
|
137
|
-
:g3-highcpu-7-kvm:
|
|
138
|
-
:name: g3-highcpu-7-kvm
|
|
139
|
-
:os: Linux
|
|
140
|
-
:cost: 0.508
|
|
141
|
-
:cpus: 7.0
|
|
142
|
-
:disk: 263
|
|
143
|
-
:ram: 7.0
|
|
144
|
-
:g3-highio-15-kvm:
|
|
145
|
-
:name: g3-highio-15-kvm
|
|
146
|
-
:os: Linux
|
|
147
|
-
:cost: 0.76
|
|
148
|
-
:cpus: 2.0
|
|
149
|
-
:disk: 360
|
|
150
|
-
:ram: 15.0
|
|
151
|
-
:g3-highio-30-kvm:
|
|
152
|
-
:name: g3-highio-30-kvm
|
|
153
|
-
:os: Linux
|
|
154
|
-
:cost: 1.52
|
|
155
|
-
:cpus: 4.0
|
|
156
|
-
:disk: 725
|
|
157
|
-
:ram: 30.0
|
|
158
|
-
:g3-highio-60.5-kvm:
|
|
159
|
-
:name: g3-highio-60.5-kvm
|
|
160
|
-
:os: Linux
|
|
161
|
-
:cost: 3.067
|
|
162
|
-
:cpus: 8.0
|
|
163
|
-
:disk: 1452
|
|
164
|
-
:ram: 60.5
|
|
165
|
-
:g3-highstorage-32-kvm:
|
|
166
|
-
:name: g3-highstorage-32-kvm
|
|
167
|
-
:os: Linux
|
|
168
|
-
:cost: 0.863
|
|
169
|
-
:cpus: 8.0
|
|
170
|
-
:disk: 7680
|
|
171
|
-
:ram: 32.0
|
|
77
|
+
:cost: 4.096
|
|
78
|
+
:cpus: 32.0
|
|
79
|
+
:disk: 4200
|
|
80
|
+
:ram: 128.0
|
|
172
81
|
:g3-highmemory-17.125-smartos:
|
|
173
82
|
:name: g3-highmemory-17.125-smartos
|
|
174
|
-
:os:
|
|
83
|
+
:os: Infrastructure Container
|
|
175
84
|
:cost: 0.409
|
|
176
85
|
:cpus: 2.0
|
|
177
86
|
:disk: 420
|
|
178
87
|
:ram: 17.13
|
|
179
88
|
:g3-highmemory-34.25-smartos:
|
|
180
89
|
:name: g3-highmemory-34.25-smartos
|
|
181
|
-
:os:
|
|
90
|
+
:os: Infrastructure Container
|
|
182
91
|
:cost: 0.817
|
|
183
92
|
:cpus: 4.0
|
|
184
93
|
:disk: 843
|
|
185
94
|
:ram: 34.25
|
|
186
95
|
:g3-highmemory-68.375-smartos:
|
|
187
96
|
:name: g3-highmemory-68.375-smartos
|
|
188
|
-
:os:
|
|
97
|
+
:os: Infrastructure Container
|
|
189
98
|
:cost: 1.63
|
|
190
99
|
:cpus: 8.0
|
|
191
100
|
:disk: 1122
|
|
192
101
|
:ram: 68.38
|
|
193
102
|
:g3-highmemory-144-smartos:
|
|
194
103
|
:name: g3-highmemory-144-smartos
|
|
195
|
-
:os:
|
|
104
|
+
:os: Infrastructure Container
|
|
196
105
|
:cost: 3.433
|
|
197
106
|
:cpus: 18.0
|
|
198
107
|
:disk: 2363
|
|
199
108
|
:ram: 144.0
|
|
200
109
|
:g3-highmemory-256-smartos-cc:
|
|
201
110
|
:name: g3-highmemory-256-smartos-cc
|
|
202
|
-
:os:
|
|
111
|
+
:os: Infrastructure Container
|
|
203
112
|
:cost: 6.102
|
|
204
113
|
:cpus: 32.0
|
|
205
114
|
:disk: 4200
|
|
206
115
|
:ram: 256.0
|
|
207
116
|
:g3-highcpu-1.75-smartos:
|
|
208
117
|
:name: g3-highcpu-1.75-smartos
|
|
209
|
-
:os:
|
|
118
|
+
:os: Infrastructure Container
|
|
210
119
|
:cost: 0.127
|
|
211
120
|
:cpus: 2.0
|
|
212
121
|
:disk: 75
|
|
213
122
|
:ram: 1.75
|
|
214
123
|
:g3-highcpu-7-smartos:
|
|
215
124
|
:name: g3-highcpu-7-smartos
|
|
216
|
-
:os:
|
|
125
|
+
:os: Infrastructure Container
|
|
217
126
|
:cost: 0.508
|
|
218
127
|
:cpus: 7.0
|
|
219
128
|
:disk: 263
|
|
220
129
|
:ram: 7.0
|
|
221
130
|
:g3-highcpu-16-smartos:
|
|
222
131
|
:name: g3-highcpu-16-smartos
|
|
223
|
-
:os:
|
|
132
|
+
:os: Infrastructure Container
|
|
224
133
|
:cost: 1.16
|
|
225
134
|
:cpus: 16.0
|
|
226
135
|
:disk: 600
|
|
227
136
|
:ram: 16.0
|
|
228
137
|
:g3-highcpu-24-smartos:
|
|
229
138
|
:name: g3-highcpu-24-smartos
|
|
230
|
-
:os:
|
|
139
|
+
:os: Infrastructure Container
|
|
231
140
|
:cost: 1.739
|
|
232
141
|
:cpus: 24.0
|
|
233
142
|
:disk: 900
|
|
234
143
|
:ram: 24.0
|
|
235
144
|
:g3-highcpu-32-smartos-cc:
|
|
236
145
|
:name: g3-highcpu-32-smartos-cc
|
|
237
|
-
:os:
|
|
146
|
+
:os: Infrastructure Container
|
|
238
147
|
:cost: 2.319
|
|
239
148
|
:cpus: 32.0
|
|
240
149
|
:disk: 1200
|
|
241
150
|
:ram: 32.0
|
|
242
151
|
:g3-highio-15-smartos:
|
|
243
152
|
:name: g3-highio-15-smartos
|
|
244
|
-
:os:
|
|
153
|
+
:os: Infrastructure Container
|
|
245
154
|
:cost: 0.76
|
|
246
155
|
:cpus: 2.0
|
|
247
156
|
:disk: 360
|
|
248
157
|
:ram: 15.0
|
|
249
158
|
:g3-highio-30-smartos:
|
|
250
159
|
:name: g3-highio-30-smartos
|
|
251
|
-
:os:
|
|
160
|
+
:os: Infrastructure Container
|
|
252
161
|
:cost: 1.52
|
|
253
162
|
:cpus: 4.0
|
|
254
163
|
:disk: 725
|
|
255
164
|
:ram: 30.0
|
|
256
165
|
:g3-highio-60.5-smartos:
|
|
257
166
|
:name: g3-highio-60.5-smartos
|
|
258
|
-
:os:
|
|
167
|
+
:os: Infrastructure Container
|
|
259
168
|
:cost: 3.067
|
|
260
169
|
:cpus: 8.0
|
|
261
170
|
:disk: 1452
|
|
262
171
|
:ram: 60.5
|
|
263
172
|
:g3-highio-128-smartos:
|
|
264
173
|
:name: g3-highio-128-smartos
|
|
265
|
-
:os:
|
|
174
|
+
:os: Infrastructure Container
|
|
266
175
|
:cost: 6.488
|
|
267
176
|
:cpus: 16.0
|
|
268
177
|
:disk: 3072
|
|
269
178
|
:ram: 128.0
|
|
270
179
|
:g3-highio-256-smartos-cc:
|
|
271
180
|
:name: g3-highio-256-smartos-cc
|
|
272
|
-
:os:
|
|
181
|
+
:os: Infrastructure Container
|
|
273
182
|
:cost: 12.976
|
|
274
183
|
:cpus: 32.0
|
|
275
184
|
:disk: 6144
|
|
@@ -295,3 +204,267 @@
|
|
|
295
204
|
:cpus: 32.0
|
|
296
205
|
:disk: 30720
|
|
297
206
|
:ram: 128.0
|
|
207
|
+
:g3-standard-0.625-kvm:
|
|
208
|
+
:name: g3-standard-0.625-kvm
|
|
209
|
+
:os: Linux
|
|
210
|
+
:cost: 0.02
|
|
211
|
+
:cpus: 0.15
|
|
212
|
+
:disk: 20
|
|
213
|
+
:ram: 0.625
|
|
214
|
+
:g3-standard-1.75-kvm:
|
|
215
|
+
:name: g3-standard-1.75-kvm
|
|
216
|
+
:os: Hardware VM
|
|
217
|
+
:cost: 0.056
|
|
218
|
+
:cpus: 1.0
|
|
219
|
+
:disk: 56
|
|
220
|
+
:ram: 1.75
|
|
221
|
+
:g3-standard-3.75-kvm:
|
|
222
|
+
:name: g3-standard-3.75-kvm
|
|
223
|
+
:os: Hardware VM
|
|
224
|
+
:cost: 0.12
|
|
225
|
+
:cpus: 1.0
|
|
226
|
+
:disk: 123
|
|
227
|
+
:ram: 3.75
|
|
228
|
+
:g3-standard-7.5-kvm:
|
|
229
|
+
:name: g3-standard-7.5-kvm
|
|
230
|
+
:os: Linux
|
|
231
|
+
:cost: 0.24
|
|
232
|
+
:cpus: 2.0
|
|
233
|
+
:disk: 738
|
|
234
|
+
:ram: 7.5
|
|
235
|
+
:g3-standard-15-kvm:
|
|
236
|
+
:name: g3-standard-15-kvm
|
|
237
|
+
:os: Linux
|
|
238
|
+
:cost: 0.48
|
|
239
|
+
:cpus: 4.0
|
|
240
|
+
:disk: 1467
|
|
241
|
+
:ram: 15.0
|
|
242
|
+
:g3-standard-30-kvm:
|
|
243
|
+
:name: g3-standard-30-kvm
|
|
244
|
+
:os: Linux
|
|
245
|
+
:cost: 0.96
|
|
246
|
+
:cpus: 8.0
|
|
247
|
+
:disk: 1683
|
|
248
|
+
:ram: 30.0
|
|
249
|
+
:g3-highmemory-17.125-kvm:
|
|
250
|
+
:name: g3-highmemory-17.125-kvm
|
|
251
|
+
:os: Hardware VM
|
|
252
|
+
:cost: 0.409
|
|
253
|
+
:cpus: 2.0
|
|
254
|
+
:disk: 420
|
|
255
|
+
:ram: 17.13
|
|
256
|
+
:g3-highmemory-34.25-kvm:
|
|
257
|
+
:name: g3-highmemory-34.25-kvm
|
|
258
|
+
:os: Hardware VM
|
|
259
|
+
:cost: 0.817
|
|
260
|
+
:cpus: 4.0
|
|
261
|
+
:disk: 843
|
|
262
|
+
:ram: 34.25
|
|
263
|
+
:g3-highmemory-68.375-kvm:
|
|
264
|
+
:name: g3-highmemory-68.375-kvm
|
|
265
|
+
:os: Hardware VM
|
|
266
|
+
:cost: 1.63
|
|
267
|
+
:cpus: 8.0
|
|
268
|
+
:disk: 1122
|
|
269
|
+
:ram: 68.38
|
|
270
|
+
:g3-highcpu-1.75-kvm:
|
|
271
|
+
:name: g3-highcpu-1.75-kvm
|
|
272
|
+
:os: Hardware VM
|
|
273
|
+
:cost: 0.127
|
|
274
|
+
:cpus: 2.0
|
|
275
|
+
:disk: 75
|
|
276
|
+
:ram: 1.75
|
|
277
|
+
:g3-highcpu-7-kvm:
|
|
278
|
+
:name: g3-highcpu-7-kvm
|
|
279
|
+
:os: Hardware VM
|
|
280
|
+
:cost: 0.508
|
|
281
|
+
:cpus: 7.0
|
|
282
|
+
:disk: 263
|
|
283
|
+
:ram: 7.0
|
|
284
|
+
:g3-highio-15-kvm:
|
|
285
|
+
:name: g3-highio-15-kvm
|
|
286
|
+
:os: Linux
|
|
287
|
+
:cost: 0.76
|
|
288
|
+
:cpus: 2.0
|
|
289
|
+
:disk: 360
|
|
290
|
+
:ram: 15.0
|
|
291
|
+
:g3-highio-30-kvm:
|
|
292
|
+
:name: g3-highio-30-kvm
|
|
293
|
+
:os: Linux
|
|
294
|
+
:cost: 1.52
|
|
295
|
+
:cpus: 4.0
|
|
296
|
+
:disk: 725
|
|
297
|
+
:ram: 30.0
|
|
298
|
+
:g3-highio-60.5-kvm:
|
|
299
|
+
:name: g3-highio-60.5-kvm
|
|
300
|
+
:os: Hardware VM
|
|
301
|
+
:cost: 3.067
|
|
302
|
+
:cpus: 8.0
|
|
303
|
+
:disk: 1452
|
|
304
|
+
:ram: 60.5
|
|
305
|
+
:g3-highstorage-32-kvm:
|
|
306
|
+
:name: g3-highstorage-32-kvm
|
|
307
|
+
:os: Linux
|
|
308
|
+
:cost: 0.863
|
|
309
|
+
:cpus: 8.0
|
|
310
|
+
:disk: 7680
|
|
311
|
+
:ram: 32.0
|
|
312
|
+
:g3-standard-8-smartos:
|
|
313
|
+
:cost: 0.26
|
|
314
|
+
:ram: 8.0
|
|
315
|
+
:cpus: 4.0
|
|
316
|
+
:disk: 738
|
|
317
|
+
:g3-highcpu-8-smartos:
|
|
318
|
+
:cost: 0.58
|
|
319
|
+
:ram: 8.0
|
|
320
|
+
:cpus: 8.0
|
|
321
|
+
:disk: 738
|
|
322
|
+
:g3-standard-0.5-smartos:
|
|
323
|
+
:cost: 0.016
|
|
324
|
+
:ram: 0.5
|
|
325
|
+
:cpus: 0.5
|
|
326
|
+
:g3-highmemory-96-smartos:
|
|
327
|
+
:cost: 2.451
|
|
328
|
+
:ram: 7.5
|
|
329
|
+
:cpus: 32.0
|
|
330
|
+
:disk: 3100
|
|
331
|
+
:t4-standard-128M:
|
|
332
|
+
:name: t4-standard-128M
|
|
333
|
+
:os: Infrastructure Container
|
|
334
|
+
:cost: 0.003
|
|
335
|
+
:cpus: 0.0625
|
|
336
|
+
:disk: 3
|
|
337
|
+
:ram: 0.128
|
|
338
|
+
:t4-standard-256M:
|
|
339
|
+
:name: t4-standard-256M
|
|
340
|
+
:os: Infrastructure Container
|
|
341
|
+
:cost: 0.007
|
|
342
|
+
:cpus: 0.125
|
|
343
|
+
:disk: 6
|
|
344
|
+
:ram: 0.256
|
|
345
|
+
:t4-standard-512M:
|
|
346
|
+
:name: t4-standard-512M
|
|
347
|
+
:os: Infrastructure Container
|
|
348
|
+
:cost: 0.013
|
|
349
|
+
:cpus: 0.25
|
|
350
|
+
:disk: 12
|
|
351
|
+
:ram: 0.512
|
|
352
|
+
:t4-standard-1G:
|
|
353
|
+
:name: t4-standard-1G
|
|
354
|
+
:os: Infrastructure Container
|
|
355
|
+
:cost: 0.026
|
|
356
|
+
:cpus: 0.5
|
|
357
|
+
:disk: 25
|
|
358
|
+
:ram: 1.0
|
|
359
|
+
:t4-standard-2G:
|
|
360
|
+
:name: t4-standard-2G
|
|
361
|
+
:os: Infrastructure Container
|
|
362
|
+
:cost: 0.053
|
|
363
|
+
:cpus: 1.0
|
|
364
|
+
:disk: 50
|
|
365
|
+
:ram: 2.0
|
|
366
|
+
:t4-standard-4G:
|
|
367
|
+
:name: t4-standard-4G
|
|
368
|
+
:os: Infrastructure Container
|
|
369
|
+
:cost: 0.105
|
|
370
|
+
:cpus: 2.0
|
|
371
|
+
:disk: 100
|
|
372
|
+
:ram: 4.0
|
|
373
|
+
:t4-standard-8G:
|
|
374
|
+
:name: t4-standard-8G
|
|
375
|
+
:os: Infrastructure Container
|
|
376
|
+
:cost: 0.21
|
|
377
|
+
:cpus: 4.0
|
|
378
|
+
:disk: 200
|
|
379
|
+
:ram: 8.0
|
|
380
|
+
:t4-standard-16G:
|
|
381
|
+
:name: t4-standard-16G
|
|
382
|
+
:os: Infrastructure Container
|
|
383
|
+
:cost: 0.42
|
|
384
|
+
:cpus: 8.0
|
|
385
|
+
:disk: 400
|
|
386
|
+
:ram: 16.0
|
|
387
|
+
:t4-standard-32G:
|
|
388
|
+
:name: t4-standard-32G
|
|
389
|
+
:os: Infrastructure Container
|
|
390
|
+
:cost: 0.84
|
|
391
|
+
:cpus: 16.0
|
|
392
|
+
:disk: 800
|
|
393
|
+
:ram: 32.0
|
|
394
|
+
:t4-standard-64G:
|
|
395
|
+
:name: t4-standard-64G
|
|
396
|
+
:os: Infrastructure Container
|
|
397
|
+
:cost: 1.68
|
|
398
|
+
:cpus: 32.0
|
|
399
|
+
:disk: 1600
|
|
400
|
+
:ram: 64.0
|
|
401
|
+
:g3-standard-1-kvm:
|
|
402
|
+
:name: g3-standard-1-kvm
|
|
403
|
+
:os: Hardware VM
|
|
404
|
+
:cost: 0.032
|
|
405
|
+
:cpus: 0.25
|
|
406
|
+
:disk: 33
|
|
407
|
+
:ram: 1.0
|
|
408
|
+
:g3-standard-2-kvm:
|
|
409
|
+
:name: g3-standard-2-kvm
|
|
410
|
+
:os: Hardware VM
|
|
411
|
+
:cost: 0.064
|
|
412
|
+
:cpus: 1.0
|
|
413
|
+
:disk: 66
|
|
414
|
+
:ram: 2.0
|
|
415
|
+
:g3-standard-4-kvm:
|
|
416
|
+
:name: g3-standard-4-kvm
|
|
417
|
+
:os: Hardware VM
|
|
418
|
+
:cost: 0.128
|
|
419
|
+
:cpus: 1.0
|
|
420
|
+
:disk: 131
|
|
421
|
+
:ram: 4.0
|
|
422
|
+
:g3-highmemory-144-kvm:
|
|
423
|
+
:name: g3-highmemory-144-kvm
|
|
424
|
+
:os: Hardware VM
|
|
425
|
+
:cost: 3.433
|
|
426
|
+
:cpus: 18.0
|
|
427
|
+
:disk: 2363
|
|
428
|
+
:ram: 144.0
|
|
429
|
+
:g3-highmemory-256-kvm-cc:
|
|
430
|
+
:name: g3-highmemory-256-kvm-cc
|
|
431
|
+
:os: Hardware VM
|
|
432
|
+
:cost: 6.102
|
|
433
|
+
:cpus: 32.0
|
|
434
|
+
:disk: 4200
|
|
435
|
+
:ram: 256.0
|
|
436
|
+
:g3-highcpu-16-kvm:
|
|
437
|
+
:name: g3-highcpu-16-kvm
|
|
438
|
+
:os: Hardware VM
|
|
439
|
+
:cost: 1.16
|
|
440
|
+
:cpus: 16.0
|
|
441
|
+
:disk: 600
|
|
442
|
+
:ram: 16.0
|
|
443
|
+
:g3-highcpu-24-kvm:
|
|
444
|
+
:name: g3-highcpu-24-kvm
|
|
445
|
+
:os: Hardware VM
|
|
446
|
+
:cost: 1.739
|
|
447
|
+
:cpus: 24.0
|
|
448
|
+
:disk: 900
|
|
449
|
+
:ram: 24.0
|
|
450
|
+
:g3-highcpu-32-kvm-cc:
|
|
451
|
+
:name: g3-highcpu-32-kvm-cc
|
|
452
|
+
:os: Hardware VM
|
|
453
|
+
:cost: 2.319
|
|
454
|
+
:cpus: 32.0
|
|
455
|
+
:disk: 1200
|
|
456
|
+
:ram: 32.0
|
|
457
|
+
:g3-highio-128-kvm:
|
|
458
|
+
:name: g3-highio-128-kvm
|
|
459
|
+
:os: Hardware VM
|
|
460
|
+
:cost: 6.488
|
|
461
|
+
:cpus: 16.0
|
|
462
|
+
:disk: 3072
|
|
463
|
+
:ram: 128.0
|
|
464
|
+
:g3-highio-256-kvm-cc:
|
|
465
|
+
:name: g3-highio-256-kvm-cc
|
|
466
|
+
:os: Hardware VM
|
|
467
|
+
:cost: 12.976
|
|
468
|
+
:cpus: 32.0
|
|
469
|
+
:disk: 6144
|
|
470
|
+
:ram: 256.0
|
data/lib/pricing.rb
CHANGED
|
@@ -8,7 +8,7 @@ module Joyent
|
|
|
8
8
|
PRICING_FILENAME = File.expand_path('../../config/joyent_pricing.yml', __FILE__)
|
|
9
9
|
LEGACY_FILENAME = File.expand_path('../../config/joyent_pricing_unpublished.yml', __FILE__)
|
|
10
10
|
COMMIT_FILENAME = 'config/commit_pricing.yml'
|
|
11
|
-
JOYENT_URL = '
|
|
11
|
+
JOYENT_URL = 'https://www.joyent.com/public-cloud/pricing'
|
|
12
12
|
HOURS_PER_MONTH = 720
|
|
13
13
|
|
|
14
14
|
end
|
data/lib/pricing/analyzer.rb
CHANGED
|
@@ -120,7 +120,7 @@ module Joyent::Cloud::Pricing
|
|
|
120
120
|
f.respond_to?(operation.to_sym) ? f.send(operation) : 0
|
|
121
121
|
end
|
|
122
122
|
end
|
|
123
|
-
{ total: results[0], unreserved: results[1], reserved: results[2] }
|
|
123
|
+
{ total: results[0].round(2), unreserved: results[1].round(2), reserved: results[2].round(2) }
|
|
124
124
|
end
|
|
125
125
|
|
|
126
126
|
|
|
@@ -148,4 +148,3 @@ module Joyent::Cloud::Pricing
|
|
|
148
148
|
|
|
149
149
|
end
|
|
150
150
|
end
|
|
151
|
-
|
data/lib/pricing/report.txt.erb
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<%- separator = ('.' * 65).cyan -%>
|
|
2
|
-
Joyent Pricing
|
|
2
|
+
Joyent Pricing @ https://github.com/kigster/joyent-cloud-pricing
|
|
3
3
|
<%= separator %>
|
|
4
4
|
<%- if have_unknown_zones? -%>
|
|
5
5
|
<%= "WARNING!".red %>: Some 'flavors' in your list were not recognized, and
|
data/lib/pricing/scraper.rb
CHANGED
|
@@ -15,12 +15,14 @@ module Joyent::Cloud::Pricing
|
|
|
15
15
|
|
|
16
16
|
def result
|
|
17
17
|
config = Hash.new
|
|
18
|
+
i = 0
|
|
18
19
|
self.doc.css('ul.full-specs').each do |ul|
|
|
19
20
|
flavor = extract_price(ul)
|
|
21
|
+
i += 1
|
|
20
22
|
next if flavor.cost.nil?
|
|
21
|
-
next if flavor.name =~ /kvm/ && flavor.os !~ /linux/i
|
|
22
23
|
config[flavor.name]= flavor.to_h
|
|
23
24
|
end
|
|
25
|
+
puts "Found #{i} elements of class 'full-specs'"
|
|
24
26
|
config
|
|
25
27
|
end
|
|
26
28
|
|
data/lib/pricing/version.rb
CHANGED
data/lib/tasks/update.rake
CHANGED
|
@@ -6,11 +6,12 @@ namespace :joyent do
|
|
|
6
6
|
task :update do
|
|
7
7
|
load_from_url = Joyent::Cloud::Pricing::JOYENT_URL
|
|
8
8
|
save_to_file = Joyent::Cloud::Pricing::PRICING_FILENAME
|
|
9
|
-
|
|
9
|
+
old_config = Joyent::Cloud::Pricing::Configuration.from_yaml
|
|
10
10
|
STDOUT.puts "downloading latest prices from #{load_from_url}"
|
|
11
|
-
|
|
12
|
-
config.
|
|
13
|
-
|
|
11
|
+
new_config = Joyent::Cloud::Pricing::Configuration.from_url(load_from_url)
|
|
12
|
+
old_config.config.merge!(new_config.config)
|
|
13
|
+
old_config.save_yaml(save_to_file)
|
|
14
|
+
STDOUT.puts "saved #{old_config.config.keys.size} image prices to #{save_to_file}"
|
|
14
15
|
end
|
|
15
16
|
end
|
|
16
17
|
end
|
|
@@ -41,8 +41,8 @@ RSpec.describe 'Joyent::Cloud::Pricing::Configuration' do
|
|
|
41
41
|
flavor = config.flavor 'g3-standard-48-smartos'
|
|
42
42
|
expect(flavor.class).to eql(Joyent::Cloud::Pricing::Flavor)
|
|
43
43
|
|
|
44
|
-
expect(flavor.ram).to eql(
|
|
45
|
-
expect(flavor.cpus).to eql(
|
|
44
|
+
expect(flavor.ram).to eql(48.0)
|
|
45
|
+
expect(flavor.cpus).to eql(12.0)
|
|
46
46
|
expect(flavor.cost).to eql(1.536)
|
|
47
47
|
end
|
|
48
48
|
end
|
|
@@ -1,29 +1,45 @@
|
|
|
1
|
+
require 'pp'
|
|
2
|
+
require 'colored'
|
|
1
3
|
require 'spec_helper'
|
|
2
4
|
|
|
5
|
+
class OutdatedFixturesExpectation < RuntimeError; end
|
|
6
|
+
def check_if_fixtures_are_outdated config, flavor
|
|
7
|
+
if !@config.nil? && !@config.empty? && @config[flavor].nil?
|
|
8
|
+
STDERR.puts "Fixtures may be outdated... Cannot find flavor #{flavor} in the scraped config\n".red +
|
|
9
|
+
"\t" + @config.keys.join("\n\t").yellow + "\n".white
|
|
10
|
+
raise OutdatedFixturesExpectation.new("Fixtures are outdatd, missing flavor #{flavor} in the hash of #{config.keys.size} flavors.")
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
|
|
3
14
|
RSpec.describe 'Joyent::Cloud::Pricing::Scraper' do
|
|
4
|
-
context 'scraping from URL'
|
|
5
15
|
let(:scraper) { Joyent::Cloud::Pricing::Scraper.new }
|
|
6
16
|
|
|
7
|
-
let(:prices) { {'
|
|
8
|
-
'g3-
|
|
9
|
-
'g3-
|
|
17
|
+
let(:prices) { {'t4-standard-64G' => 1.68,
|
|
18
|
+
'g3-highcpu-1.75-smartos' =>0.127,
|
|
19
|
+
'g3-highio-60.5-kvm' => 3.067
|
|
10
20
|
} }
|
|
11
21
|
|
|
12
|
-
let(:cpus) { {'
|
|
13
|
-
'g3-
|
|
14
|
-
'g3-
|
|
22
|
+
let(:cpus) { {'t4-standard-64G' => 32.0,
|
|
23
|
+
'g3-highcpu-1.75-smartos' => 2.0,
|
|
24
|
+
'g3-highio-60.5-kvm' => 8.0
|
|
15
25
|
} }
|
|
16
26
|
|
|
27
|
+
|
|
17
28
|
before do
|
|
18
29
|
@config = scraper.scrape
|
|
19
30
|
end
|
|
20
31
|
|
|
21
32
|
it 'should load pricing configuration hash from Joyent Website' do
|
|
33
|
+
puts "Scraped #{@config.keys.size} flavors from URL [".white + "#{Joyent::Cloud::Pricing::JOYENT_URL}".yellow + "]".white
|
|
22
34
|
prices.keys.each do |flavor|
|
|
23
|
-
|
|
35
|
+
check_if_fixtures_are_outdated @config, flavor
|
|
36
|
+
expect(@config[flavor][:cost]).to \
|
|
37
|
+
eql(prices[flavor])
|
|
24
38
|
end
|
|
25
39
|
cpus.keys.each do |flavor|
|
|
26
|
-
|
|
40
|
+
check_if_fixtures_are_outdated @config, flavor
|
|
41
|
+
expect(@config[flavor][:cpus]).to \
|
|
42
|
+
eql(cpus[flavor])
|
|
27
43
|
end
|
|
28
44
|
end
|
|
29
45
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: joyent-cloud-pricing
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.1.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Konstantin Gredeskoul
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2016-02-14 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: nokogiri
|
|
@@ -130,6 +130,7 @@ executables: []
|
|
|
130
130
|
extensions: []
|
|
131
131
|
extra_rdoc_files: []
|
|
132
132
|
files:
|
|
133
|
+
- ".atom-build.json"
|
|
133
134
|
- ".coveralls.yml"
|
|
134
135
|
- ".gitignore"
|
|
135
136
|
- ".rspec"
|
|
@@ -190,7 +191,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
190
191
|
version: '0'
|
|
191
192
|
requirements: []
|
|
192
193
|
rubyforge_project:
|
|
193
|
-
rubygems_version: 2.
|
|
194
|
+
rubygems_version: 2.4.5.1
|
|
194
195
|
signing_key:
|
|
195
196
|
specification_version: 4
|
|
196
197
|
summary: Tools for calculating monthly and yearly price of infrastructure hosted on
|
|
@@ -209,4 +210,3 @@ test_files:
|
|
|
209
210
|
- spec/pricing/reserve_spec.rb
|
|
210
211
|
- spec/pricing/scraper_spec.rb
|
|
211
212
|
- spec/spec_helper.rb
|
|
212
|
-
has_rdoc:
|