24 lines
480 B
Python
24 lines
480 B
Python
"""Run one command in an ephemeral VM through the public Python SDK."""
|
|
|
|
from __future__ import annotations
|
|
|
|
import json
|
|
|
|
from pyro_mcp import Pyro
|
|
|
|
|
|
def main() -> None:
|
|
pyro = Pyro()
|
|
result = pyro.run_in_vm(
|
|
environment="debian:12",
|
|
command="git --version",
|
|
vcpu_count=1,
|
|
mem_mib=1024,
|
|
timeout_seconds=30,
|
|
network=False,
|
|
)
|
|
print(json.dumps(result, indent=2, sort_keys=True))
|
|
|
|
|
|
if __name__ == "__main__":
|
|
main()
|