daytona 0.167.0 → 0.169.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/lib/daytona/sandbox.rb +26 -0
- data/lib/daytona/sdk/version.rb +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 28e1fc1ed1de12c3b6b75ea5139f017a47a05ac1eccfeafe12bf83ca05630dce
|
|
4
|
+
data.tar.gz: 3c90d34114f7d88886805c4d930598f80e1383f41944665854cf7b2f28b15a6b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b909a3cffec0bcafee0ad2014f599451ea7ca4b24ca06594c0089b588f9df402d6d8bbcd2f7c8509d2932386b59f387b42551d91226f92b8ee97d9ae19ab69ee
|
|
7
|
+
data.tar.gz: 0decb6b358697e64700b7c6f192644b59fd939fa9393f4fa906464c17d75c0c4dd6e0273231202a4e38fdb650eb89d30aeafb0eb0c5ccc1dbf666eb2a34c161d
|
data/lib/daytona/sandbox.rb
CHANGED
|
@@ -87,6 +87,9 @@ module Daytona
|
|
|
87
87
|
# @return [String] The last update timestamp of the sandbox
|
|
88
88
|
attr_reader :updated_at
|
|
89
89
|
|
|
90
|
+
# @return [String] The last activity timestamp of the sandbox
|
|
91
|
+
attr_reader :last_activity_at
|
|
92
|
+
|
|
90
93
|
# @return [String] The version of the daemon running in the sandbox
|
|
91
94
|
attr_reader :daemon_version
|
|
92
95
|
|
|
@@ -199,6 +202,27 @@ module Daytona
|
|
|
199
202
|
@auto_delete_interval = interval
|
|
200
203
|
end
|
|
201
204
|
|
|
205
|
+
# Updates outbound network policy on the runner (block all, restore access, or CIDR allow list).
|
|
206
|
+
#
|
|
207
|
+
# @param network_block_all [Boolean, nil]
|
|
208
|
+
# @param network_allow_list [String, nil]
|
|
209
|
+
# @return [void]
|
|
210
|
+
# @raise [Daytona::Sdk::Error]
|
|
211
|
+
def update_network_settings(network_block_all: nil, network_allow_list: nil)
|
|
212
|
+
if network_block_all.nil? && network_allow_list.nil?
|
|
213
|
+
raise Sdk::Error,
|
|
214
|
+
'At least one of network_block_all or network_allow_list must be provided'
|
|
215
|
+
end
|
|
216
|
+
|
|
217
|
+
body = DaytonaApiClient::UpdateSandboxNetworkSettings.new(
|
|
218
|
+
network_block_all:,
|
|
219
|
+
network_allow_list:
|
|
220
|
+
)
|
|
221
|
+
data = sandbox_api.update_network_settings(id, body)
|
|
222
|
+
@network_block_all = data.network_block_all
|
|
223
|
+
@network_allow_list = data.network_allow_list
|
|
224
|
+
end
|
|
225
|
+
|
|
202
226
|
# Sets the auto-stop interval for the Sandbox.
|
|
203
227
|
# The Sandbox will automatically stop after being idle (no new events) for the specified interval.
|
|
204
228
|
# Events include any state changes or interactions with the Sandbox through the SDK.
|
|
@@ -507,6 +531,7 @@ module Daytona
|
|
|
507
531
|
end
|
|
508
532
|
|
|
509
533
|
instrument :archive, :auto_archive_interval=, :auto_delete_interval=, :auto_stop_interval=,
|
|
534
|
+
:update_network_settings,
|
|
510
535
|
:create_ssh_access, :delete, :get_user_home_dir, :get_work_dir, :labels=,
|
|
511
536
|
:preview_url, :create_signed_preview_url, :expire_signed_preview_url,
|
|
512
537
|
:refresh, :refresh_activity, :revoke_ssh_access, :start, :recover, :stop,
|
|
@@ -564,6 +589,7 @@ module Daytona
|
|
|
564
589
|
@build_info = sandbox_dto.build_info
|
|
565
590
|
@created_at = sandbox_dto.created_at
|
|
566
591
|
@updated_at = sandbox_dto.updated_at
|
|
592
|
+
@last_activity_at = sandbox_dto.last_activity_at
|
|
567
593
|
@daemon_version = sandbox_dto.daemon_version
|
|
568
594
|
@network_block_all = sandbox_dto.network_block_all
|
|
569
595
|
@network_allow_list = sandbox_dto.network_allow_list
|
data/lib/daytona/sdk/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: daytona
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.169.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Daytona Platforms Inc.
|
|
@@ -85,28 +85,28 @@ dependencies:
|
|
|
85
85
|
requirements:
|
|
86
86
|
- - '='
|
|
87
87
|
- !ruby/object:Gem::Version
|
|
88
|
-
version: 0.
|
|
88
|
+
version: 0.169.0
|
|
89
89
|
type: :runtime
|
|
90
90
|
prerelease: false
|
|
91
91
|
version_requirements: !ruby/object:Gem::Requirement
|
|
92
92
|
requirements:
|
|
93
93
|
- - '='
|
|
94
94
|
- !ruby/object:Gem::Version
|
|
95
|
-
version: 0.
|
|
95
|
+
version: 0.169.0
|
|
96
96
|
- !ruby/object:Gem::Dependency
|
|
97
97
|
name: daytona_toolbox_api_client
|
|
98
98
|
requirement: !ruby/object:Gem::Requirement
|
|
99
99
|
requirements:
|
|
100
100
|
- - '='
|
|
101
101
|
- !ruby/object:Gem::Version
|
|
102
|
-
version: 0.
|
|
102
|
+
version: 0.169.0
|
|
103
103
|
type: :runtime
|
|
104
104
|
prerelease: false
|
|
105
105
|
version_requirements: !ruby/object:Gem::Requirement
|
|
106
106
|
requirements:
|
|
107
107
|
- - '='
|
|
108
108
|
- !ruby/object:Gem::Version
|
|
109
|
-
version: 0.
|
|
109
|
+
version: 0.169.0
|
|
110
110
|
- !ruby/object:Gem::Dependency
|
|
111
111
|
name: dotenv
|
|
112
112
|
requirement: !ruby/object:Gem::Requirement
|