Module: Bsdkrun
- Defined in:
- lib/bsdkrun.rb,
lib/bsdkrun/args.rb,
lib/bsdkrun/types.rb,
lib/bsdkrun/binary.rb,
lib/bsdkrun/client.rb,
lib/bsdkrun/errors.rb,
lib/bsdkrun/images.rb,
lib/bsdkrun/system.rb,
lib/bsdkrun/process.rb,
lib/bsdkrun/sandbox.rb,
lib/bsdkrun/version.rb,
lib/bsdkrun/volumes.rb,
lib/bsdkrun/networks.rb,
lib/bsdkrun/ws_client.rb,
lib/bsdkrun/shell_session.rb,
lib/bsdkrun/websocket_frame.rb
Overview
bsdkrun — a Ruby SDK for bsdkrun, a
Firecracker-style microVM launcher for BSD, Linux, and unikernel guests. A thin wrapper
around the bsdkrun CLI: it builds argv, shells out, and parses JSON output.
Defined Under Namespace
Modules: Args, Binary, Images, Networks, Process, System, Volumes, WebSocketFrame Classes: AuthError, BinaryNotFound, Client, CommandFailed, CommandResult, Error, ExecResult, GraphQLError, ImageInfo, NetworkInfo, PortForward, Result, Sandbox, SandboxInfo, SandboxNotFound, ShellSession, ShellSessionInfo, VolumeInfo, WsClient
Constant Summary collapse
- VERSION =
The bsdkrun Ruby SDK version.
"0.3.0"
Class Method Summary collapse
-
.binary_path ⇒ String
The resolved
bsdkrunbinary path. -
.binary_path=(path) ⇒ void
Force the SDK to use a specific
bsdkrunbinary, bypassing discovery. -
.create(opts = {}, **kwargs) ⇒ Sandbox
Convenience alias for Sandbox.create.
-
.get(id) ⇒ Sandbox
Convenience alias for Sandbox.get.
-
.images ⇒ Module
The Images namespace.
-
.list(all: false) ⇒ Array<SandboxInfo>
Convenience alias for Sandbox.list.
-
.networks ⇒ Module
The Networks namespace.
-
.reset_binary! ⇒ void
Reset cached binary discovery state (mainly for tests).
-
.system ⇒ Module
The System namespace.
-
.volumes ⇒ Module
The Volumes namespace.
Class Method Details
.binary_path ⇒ String
Returns the resolved bsdkrun binary path.
40 41 42 |
# File 'lib/bsdkrun.rb', line 40 def binary_path Binary.resolve end |
.binary_path=(path) ⇒ void
This method returns an undefined value.
Force the SDK to use a specific bsdkrun binary, bypassing discovery.
34 35 36 |
# File 'lib/bsdkrun.rb', line 34 def binary_path=(path) Binary.override = path end |
.create(opts = {}, **kwargs) ⇒ Sandbox
Convenience alias for Bsdkrun::Sandbox.create.
52 53 54 |
# File 'lib/bsdkrun.rb', line 52 def create(opts = {}, **kwargs) Sandbox.create(opts, **kwargs) end |
.get(id) ⇒ Sandbox
Convenience alias for Bsdkrun::Sandbox.get.
58 59 60 |
# File 'lib/bsdkrun.rb', line 58 def get(id) Sandbox.get(id) end |
.images ⇒ Module
The Images namespace.
70 71 72 |
# File 'lib/bsdkrun.rb', line 70 def images Images end |
.list(all: false) ⇒ Array<SandboxInfo>
Convenience alias for Bsdkrun::Sandbox.list.
64 65 66 |
# File 'lib/bsdkrun.rb', line 64 def list(all: false) Sandbox.list(all: all) end |
.networks ⇒ Module
The Networks namespace.
82 83 84 |
# File 'lib/bsdkrun.rb', line 82 def networks Networks end |
.reset_binary! ⇒ void
This method returns an undefined value.
Reset cached binary discovery state (mainly for tests).
46 47 48 |
# File 'lib/bsdkrun.rb', line 46 def reset_binary! Binary.reset! end |