fly_io 0.1.0 → 0.1.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4dd8c23a72b3368728387726a4f9c0f549f964c73031fd210f8a452e0b635fed
4
- data.tar.gz: 5c7cde4c9562e3a5e422b31c253f62eaa27de501e4ee80ef2a045c4934444f46
3
+ metadata.gz: 228516dfe92da54a7220aa8dcaff8b762b564ae9e238ef5bb62e58329e07491f
4
+ data.tar.gz: 5c24f6d0b9d47323c5c5a394f3887afa35396c94ba66b0dabda6c31815e2786e
5
5
  SHA512:
6
- metadata.gz: 537aacc7de6c237c6acfb03107d96c4244ba0e94338e819ec5ac9bd16ca2af122b25abcc143f9e58eee2eeb43d35f70b990f120546266c1db87417ab9eb142a3
7
- data.tar.gz: 18fb6ba50789303ed0b90154dd650822accbd1c21d4852afbd3bec80876b21167e5597e2f2b5c714c8acff081c17145c46038897eac192d6b1ed2f38a753b2fe
6
+ metadata.gz: 32ea12bea8615df7aaa70fcefd6bf735f88048ecb3a17b212f371f519f6bc7d4ca7628e1287692c6513f7d3f4a998796f19b05610d604df975be5cb7af344c48
7
+ data.tar.gz: 4271122f84162ab0bbca7b9434ab1886a3c7f95ff5762a3da0c879317f0f7022bbeb220c1a172c63729c910f015ba4f93a153af71f5798225d0d46009fc16819
data/CHANGELOG.md CHANGED
@@ -4,6 +4,12 @@ All notable changes follow [Keep a Changelog](https://keepachangelog.com/) and S
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [0.1.1] - 2026-08-27
8
+
9
+ ### Added
10
+
11
+ - Optional custom-network selection when destroying an app.
12
+
7
13
  ## [0.1.0] - 2026-08-26
8
14
 
9
15
  ### Added
data/README.md CHANGED
@@ -45,6 +45,13 @@ client.machines.start(app_name: "my-app", machine_id: machine.id)
45
45
  client.machines.wait(app_name: "my-app", machine_id: machine.id, state: "started", timeout: 60)
46
46
  ```
47
47
 
48
+ When destroying an app, pass its selected custom private network to delete the attachment along with the app. Omit
49
+ `network:` for apps on the default network:
50
+
51
+ ```ruby
52
+ client.apps.destroy(app_name: "my-app", network: "customer-network")
53
+ ```
54
+
48
55
  Resource methods return `FlyIO::Response`. `response.body` is coerced to the documented `FlyIO::Models::*` class (or
49
56
  an array/primitive where the contract says so), while response methods delegate to a model for concise code such as
50
57
  `machine.id`. Models keep unknown fields and preserve exact wire keys for forward compatibility.
@@ -16,14 +16,14 @@ module FlyIO
16
16
 
17
17
  private
18
18
 
19
- def invoke(operation, arguments)
19
+ def invoke(operation, arguments, extra_query: {})
20
20
  arguments = arguments.dup
21
21
  body = arguments.delete(:body) { FlyIO::UNSET }
22
22
  extra_headers = arguments.delete(:headers) || {}
23
23
  retry_unsafe = arguments.delete(:retry_unsafe)
24
24
  request_timeout = arguments.delete(:request_timeout)
25
25
  path_params = {}
26
- query = {}
26
+ query = extra_query.dup
27
27
  operation_headers = {}
28
28
 
29
29
  operation.parameters.each do |parameter|
@@ -2,6 +2,16 @@
2
2
 
3
3
  module FlyIO
4
4
  module Resources
5
+ class Apps < Base
6
+ def destroy(network: nil, **arguments)
7
+ operation = OperationRegistry.fetch("Apps_delete")
8
+ SchemaValidator.validate!({"type" => "string"}, network, location: "network") unless network.nil?
9
+ extra_query = network.nil? ? {} : {"network" => network}
10
+
11
+ invoke(operation, arguments, extra_query: extra_query)
12
+ end
13
+ end
14
+
5
15
  module_function
6
16
 
7
17
  def install!
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module FlyIO
4
- VERSION = "0.1.0"
4
+ VERSION = "0.1.1"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fly_io
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vito Botta