Python SDK for the Arrakis sandboxes - https://github.com/abshkbh/arrakis
Project description
py-arrakis
Python SDK for Arrakis.
Description
This package provides a Python SDK over the REST API exposed by Arrakis.
Installation
pip install py-arrakis
Usage
The SDK provides a simple interface to manage Arrakis sandbox VMs:
from py_arrakis import SandboxManager
# Initialize the sandbox manager with the Arrakis server URL
manager = SandboxManager("http://localhost:7000")
# List all VMs
sandboxes = manager.list_all()
# Start a new VM
sandbox = manager.start_sandbox("my-sandbox")
# Run a command in the VM
result = sandbox.run_cmd("echo hello world")
print(result["output"])
# Create a snapshot
snapshot_id = sandbox.snapshot("snapshot-v1")
# Destroy the VM when done
sandbox.destroy()
# Restore from snapshot
restored_sandbox = manager.restore("my-vm", snapshot_id)
For more examples, check out the cookbook.py file.
License
MIT
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
py-arrakis-2.0.0.tar.gz
(5.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file py-arrakis-2.0.0.tar.gz.
File metadata
- Download URL: py-arrakis-2.0.0.tar.gz
- Upload date:
- Size: 5.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 colorama/0.4.4 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.9.1 requests/2.25.1 rfc3986/1.5.0 tqdm/4.57.0 urllib3/1.26.5 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bec73db66fdc6f7b2bd0ab44e4016289aa4feb1938203ee7cdc9da9240224362
|
|
| MD5 |
ac018ce0d294aab45d5ef9ceb74925ad
|
|
| BLAKE2b-256 |
44d6664b858a283e30a3407bc16675965c567980e0b98a78cb72a099655e8d01
|
File details
Details for the file py_arrakis-2.0.0-py3-none-any.whl.
File metadata
- Download URL: py_arrakis-2.0.0-py3-none-any.whl
- Upload date:
- Size: 6.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 colorama/0.4.4 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.9.1 requests/2.25.1 rfc3986/1.5.0 tqdm/4.57.0 urllib3/1.26.5 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3118dee89f4eef8c9df8facbab3d510c566bcfd9b27afe6d1c1fe2ac0bea0aba
|
|
| MD5 |
e18b975575444dc2fb5835e05162676f
|
|
| BLAKE2b-256 |
594efbd1631312c8fbb8395c093eb17d6531e6dec35affbaf6a194b971a12cbc
|