fog-brightbox 1.8.1 → 1.9.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1061e46a1ab7bab3542b35bd9a37f966370f5ab44c98d9ce003c56aecabbea47
4
- data.tar.gz: '09abdac10bca6dbafddf1a7931d0243456caf605c62757e05353b9f8611bf9ab'
3
+ metadata.gz: 9ad897388f8cd83ba70c06515b952c0ed907b3c330b59c131735c1184a776b94
4
+ data.tar.gz: d179bdcaf55265e2abfc30471b5cd6aa6b9166e7747b397e90cbaf56edecd372
5
5
  SHA512:
6
- metadata.gz: b587653fc85f39d14e3a9a46bdbff8d83b79046f3fa9baf9de12258db58d3e03c68e22b8930c409c3c5fa2209fc04606fd2d9089737321aaf28bff1c66c3e79f
7
- data.tar.gz: eff1f83c2b30a808b6b569e73c321788838c2887a9844a129137789c0052fb260e613c71497bc73733d922381d8759615284407c13fc514b1c650adff255f326
6
+ metadata.gz: 14da7c849f1500a55087c0ca2259a8f8c3cb2bf6027ae6443b9e7120f022aabb4f86bf7d5be74b4afa6eb748f6b16e5bda7db9afcc31e9801644d697f6d6d1e4
7
+ data.tar.gz: '013270008004a3d049f7a3b6a63d524da197aba1cfbabc9d936b6bb66bfc8f66f4fa3749de7c945fb9cf2a98252ca40f9b15f492dc6948d7a96a5255ee09c21d'
@@ -26,8 +26,7 @@ jobs:
26
26
  - name: Set up Ruby
27
27
  # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
28
28
  # change this to (see https://github.com/ruby/setup-ruby#versioning):
29
- # uses: ruby/setup-ruby@v1
30
- uses: ruby/setup-ruby@473e4d8fe5dd94ee328fdfca9f8c9c7afc9dae5e
29
+ uses: ruby/setup-ruby@v1
31
30
  with:
32
31
  ruby-version: ${{ matrix.ruby-version }}
33
32
  bundler-cache: true # runs 'bundle install' and caches installed gems automatically
data/CHANGELOG.md CHANGED
@@ -1,3 +1,25 @@
1
+ ### 1.9.0 / 2023-01-09
2
+
3
+ Enhancements:
4
+
5
+ * Expose read-only `Volume.zone` attribute on model to report which zone the
6
+ volume was allocated to
7
+ * Add `boot` argument to `Volume#attach` to allow changing the boot volume of
8
+ inactive servers via the model API by passing through to the API request
9
+
10
+ Changes:
11
+
12
+ * Fix Github actions `setup-ruby` version to pick up bug fixes in running tests
13
+ caused by the older templates mismatching Ruby/Bundler versions
14
+ * Correct CHANGELOG for mixed references of "enhancements" and minor "changes"
15
+
16
+ ### 1.8.2 / 2022-12-06
17
+
18
+ Bug fixes:
19
+
20
+ * Fix issue in storage directory `#save` that prevented creating and updating
21
+ permissions/ACL on Orbit containers correctly
22
+
1
23
  ### 1.8.1 / 2022-12-05
2
24
 
3
25
  Bug fixes:
@@ -7,7 +29,7 @@ Bug fixes:
7
29
 
8
30
  ### 1.8.0 / 2022-08-31
9
31
 
10
- Changes:
32
+ Enhancements:
11
33
 
12
34
  * Allow custom `volume_size` in server creation where supported
13
35
 
@@ -31,7 +53,7 @@ Bug fixes:
31
53
 
32
54
  ### 1.7.0 / 2022-07-28
33
55
 
34
- Changes:
56
+ Enhancements:
35
57
 
36
58
  * Adds support for `ConfigMaps` which are simple key/value stores for configuring
37
59
  other resources.
@@ -40,7 +62,7 @@ Changes:
40
62
 
41
63
  ### 1.6.0 / 2022-07-25
42
64
 
43
- Changes:
65
+ Enhancements:
44
66
 
45
67
  * Added support to opt-in to support Brightbox 2FA within clients.
46
68
 
@@ -62,7 +84,7 @@ object.
62
84
 
63
85
  ### 1.5.0 / 2022-06-09
64
86
 
65
- Changes:
87
+ Enhancements:
66
88
 
67
89
  * Added support for `Volume` resources. These are dynamic, network attached
68
90
  volumes. Servers with `nbs` (Network Block Storage) types can be created
@@ -93,20 +115,20 @@ Bug fixes:
93
115
 
94
116
  ### 1.4.0 / 2021-02-17
95
117
 
96
- Changes:
118
+ Enhancements:
97
119
 
98
120
  * Relax dependencies to allow Ruby 3.0 to be used.
99
121
 
100
122
  ### 1.3.0 / 2020-11-24
101
123
 
102
- Changes:
124
+ Enhancements:
103
125
 
104
126
  * Add `Server#disk_encrypted` attribute to support creation of servers with
105
127
  LUKS based encryption at rest.
106
128
 
107
129
  ### 1.2.0 / 2020-11-16
108
130
 
109
- Changes:
131
+ Enhancements:
110
132
 
111
133
  * Add `LoadBalancer#ssl_minimum_version` attribute to configure the TLS/SSL
112
134
  version supported by the load balancer.
@@ -34,6 +34,7 @@ module Fog
34
34
  attribute :account_id, aliases: "account", squash: "id"
35
35
  attribute :image_id, aliases: "image", squash: "id"
36
36
  attribute :server_id, aliases: "server", squash: "id"
37
+ attribute :zone_id, aliases: "zone", squash: "id"
37
38
 
38
39
  def attach(server)
39
40
  requires :identity
@@ -39,8 +39,8 @@ module Fog
39
39
  def save
40
40
  requires :key
41
41
  options = {
42
- "read_permissions" => read_permissions,
43
- "write_permissions" => write_permissions
42
+ read_permissions: read_permissions,
43
+ write_permissions: write_permissions
44
44
  }
45
45
  service.put_container(key, options)
46
46
  true
@@ -1,5 +1,5 @@
1
1
  module Fog
2
2
  module Brightbox
3
- VERSION = "1.8.1"
3
+ VERSION = "1.9.0"
4
4
  end
5
5
  end
@@ -0,0 +1,50 @@
1
+ require "minitest/autorun"
2
+ require "fog/brightbox"
3
+ require "fog/brightbox/models/storage/directory"
4
+
5
+ describe Fog::Brightbox::Storage::Directory do
6
+ include StockStorageResponses
7
+
8
+ let(:config) { Fog::Brightbox::Config.new(settings) }
9
+ let(:service) { Fog::Brightbox::Storage.new(config) }
10
+
11
+ describe ".create" do
12
+ let(:settings) do
13
+ {
14
+ :brightbox_client_id => "cli-12345",
15
+ :brightbox_secret => "fdkls"
16
+ }
17
+ end
18
+ let(:read_permissions) { ".r:*" }
19
+ let(:write_permissions) { "*:*" }
20
+
21
+ before do
22
+ stub_request(:get, "https://orbit.brightbox.com/v1").
23
+ to_return(authorized_response)
24
+
25
+ stub_request(:put, "https://orbit.brightbox.com/v1/acc-12345/container-name").
26
+ to_return(status: 201)
27
+ end
28
+
29
+ it do
30
+ directory = service.directories.create(
31
+ service: service,
32
+ key: "container-name",
33
+ read_permissions: read_permissions,
34
+ write_permissions: write_permissions
35
+ )
36
+
37
+ assert directory.read_permissions, read_permissions
38
+ assert directory.write_permissions, write_permissions
39
+
40
+ assert_requested(
41
+ :put,
42
+ "https://orbit.brightbox.com/v1/acc-12345/container-name",
43
+ headers: {
44
+ "X-Container-Read" => read_permissions,
45
+ "X-Container-Write" => write_permissions
46
+ }
47
+ )
48
+ end
49
+ end
50
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fog-brightbox
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.1
4
+ version: 1.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Thornthwaite
@@ -403,6 +403,7 @@ files:
403
403
  - spec/fog/brightbox/storage/config_spec.rb
404
404
  - spec/fog/brightbox/storage/connection_errors_spec.rb
405
405
  - spec/fog/brightbox/storage/connection_spec.rb
406
+ - spec/fog/brightbox/storage/directory_spec.rb
406
407
  - spec/fog/brightbox/storage/escape_spec.rb
407
408
  - spec/fog/brightbox/storage/files_spec.rb
408
409
  - spec/fog/brightbox/storage_spec.rb
@@ -516,6 +517,7 @@ test_files:
516
517
  - spec/fog/brightbox/storage/config_spec.rb
517
518
  - spec/fog/brightbox/storage/connection_errors_spec.rb
518
519
  - spec/fog/brightbox/storage/connection_spec.rb
520
+ - spec/fog/brightbox/storage/directory_spec.rb
519
521
  - spec/fog/brightbox/storage/escape_spec.rb
520
522
  - spec/fog/brightbox/storage/files_spec.rb
521
523
  - spec/fog/brightbox/storage_spec.rb