droplet_kit 3.10.0 → 3.14.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: b2033711a4b71e23fa0066e8918dbe57798bf597125a73daa19e899f47394b25
4
- data.tar.gz: a6c6dfd3c811c9221d48d48f2f9f67476ef7967938fe690072687c0dce3933f6
3
+ metadata.gz: 43d8d9788a8a3bd619b79d2c07b6eaab10f3bdf8ed6ee47e991d74f7723b0607
4
+ data.tar.gz: 5e9b8b58b1114534914c7bcc279b6cc8acb4aa8c3d2affa40f9c56eccbe79615
5
5
  SHA512:
6
- metadata.gz: ba9269398ad9ee84c3f45fd6a9a9ed91d2779b3330208323a256c3cb1bb64a5d18a547fc95d93ede3d23f01f84084d788a95764e58c33b7e5a38ffa6bed205a9
7
- data.tar.gz: de3b637394f1fc2b4fe76819796904cb00dea14e39769694d6e57a7ebff89a4bd165c78d3346e208e499c0b5afa7cc08f1537008c16cde07ce135816a177c29a
6
+ metadata.gz: ca07fe070541c8750a090a3c0084754126fef41b8984338858611f1e9e3a4d00b953e70d23e84f48000e0b61a8b0bc8b124f8886ad8958964ef40104c950ccdd
7
+ data.tar.gz: 8fd957e58eed544ccbc6e4cfcb9af91e9b5683be1cae2bcb9cdee42cb4299a85e83865fb5aca87f3dc428882197c1c690e5afc44741252986a40cfef43f90c31
data/README.md CHANGED
@@ -1,5 +1,5 @@
1
1
  # DropletKit
2
- [![Build Status](https://travis-ci.org/digitalocean/droplet_kit.svg?branch=master)](https://travis-ci.org/digitalocean/droplet_kit)
2
+ [![Build Status](https://github.com/digitalocean/droplet_kit/workflows/CI/badge.svg?branch=main)](https://github.com/digitalocean/droplet_kit/actions)
3
3
  [![Gem Version](https://badge.fury.io/rb/droplet_kit.svg)](https://badge.fury.io/rb/droplet_kit)
4
4
 
5
5
  DropletKit is the official [DigitalOcean V2 API](https://developers.digitalocean.com/v2/) client. It supports everything the API can do with a simple interface written in Ruby.
@@ -284,7 +284,8 @@ inbound_rule = DropletKit::FirewallInboundRule.new(
284
284
  ports: '0',
285
285
  sources: {
286
286
  tags: ['frontend', 'backend'],
287
- load_balancer_uids: ['d2d3920a-9d45-41b0-b018-d15e18ec60a4']
287
+ load_balancer_uids: ['d2d3920a-9d45-41b0-b018-d15e18ec60a4'],
288
+ kubernetes_ids: ['a47b6fb1-4791-4b29-aae1-2b1b9f68a2da']
288
289
  }
289
290
  )
290
291
 
@@ -6,7 +6,7 @@ module DropletKit
6
6
  mapping DatabaseUser
7
7
  root_key singular: 'user', plural: 'users', scopes: [:read]
8
8
 
9
- property :name, scopes: [:read]
9
+ property :name, scopes: [:read, :create]
10
10
  property :role, scopes: [:read, :create]
11
11
  property :password, scopes: [:read, :create]
12
12
  end
@@ -12,6 +12,7 @@ module DropletKit
12
12
  property :status
13
13
  property :created_at
14
14
  property :region, include: RegionMapping
15
+ property :size
15
16
  property :vpc_uuid
16
17
  end
17
18
 
@@ -30,6 +31,7 @@ module DropletKit
30
31
 
31
32
  scoped :update, :create do
32
33
  property :region
34
+ property :size
33
35
  end
34
36
 
35
37
  scoped :create do
@@ -20,6 +20,7 @@ module DropletKit
20
20
  scoped :update, :patch do
21
21
  property :name
22
22
  property :description
23
+ property :default
23
24
  end
24
25
 
25
26
  scoped :create do
@@ -30,4 +31,4 @@ module DropletKit
30
31
  end
31
32
  end
32
33
  end
33
- end
34
+ end
@@ -8,6 +8,7 @@ module DropletKit
8
8
  attribute :created_at
9
9
  attribute :tag
10
10
  attribute :region
11
+ attribute :size
11
12
  attribute :redirect_http_to_https, Boolean, :default => false
12
13
  attribute :enable_proxy_protocol, Boolean, :default => false
13
14
  attribute :enable_backend_keepalive, Boolean, :default => false
@@ -4,7 +4,7 @@ module DropletKit
4
4
 
5
5
  resources do
6
6
  action :all, 'GET /v2/domains/:for_domain/records' do
7
- query_keys :per_page, :page
7
+ query_keys :per_page, :page, :name, :type
8
8
  handler(200) { |response| DomainRecordMapping.extract_collection(response.body, :read) }
9
9
  end
10
10
 
@@ -49,7 +49,7 @@ module DropletKit
49
49
  resources.to_a.map do |resource|
50
50
  if resource.is_a?(String) && DropletKit::BaseModel.valid_urn?(resource)
51
51
  resource
52
- elsif resource.try(:urn) && DropletKit::BaseModel.valid_urn?(resource.urn)
52
+ elsif resource.respond_to?(:urn) && resource.urn && DropletKit::BaseModel.valid_urn?(resource.urn)
53
53
  resource.urn
54
54
  else
55
55
  raise DropletKit::Error.new("cannot assign resource without valid urn: #{resource}")
@@ -1,3 +1,3 @@
1
1
  module DropletKit
2
- VERSION = "3.10.0"
2
+ VERSION = "3.14.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: droplet_kit
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.10.0
4
+ version: 3.14.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - DigitalOcean API Engineering team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-09-08 00:00:00.000000000 Z
11
+ date: 2021-05-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: virtus
@@ -324,7 +324,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
324
324
  - !ruby/object:Gem::Version
325
325
  version: '0'
326
326
  requirements: []
327
- rubygems_version: 3.1.2
327
+ rubygems_version: 3.2.15
328
328
  signing_key:
329
329
  specification_version: 4
330
330
  summary: Droplet Kit is the official Ruby library for DigitalOcean's API