A Python module for the FreeNAS websocket API.
Project description
Python Module for FreeNAS Websocket API
This python module utilizes the FreeNAS Websocket API to get state from a FreeNAS instance.
Installation
pip install pyfreenas
Usage
from pyfreenas import Machine as FreeNASMachine
machine = await Machine.create(
"hostname.of.machine",
username="someuser",
password="password",
)
await machine.refresh()
Machine
Object representing a FreeNAS instance.
Disks
Available from machine.disks
, contains information about the disks attached to the machine.
VirturalMachines
Available from machine.vms
, contains information about the virtural machines available on the machine.
Each instance has the following methods availabe:
vm.start
vm.stop
vm.restart
Development
python3.8 -m venv .venv
source .venv/bin/activate
# Install Requirements
pip install -r requirements.txt
# Install Dev Requirements
pip install -r requirements-dev.txt
# One-Time Install of Commit Hooks
pre-commit install
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pyfreenas-0.1.0.tar.gz
(5.4 kB
view hashes)
Built Distribution
Close
Hashes for pyfreenas-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2f43f4a986f1a546c14b458281217b922eb157451a325c70a8d7a99f9406c7b7 |
|
MD5 | 1dce9f9973d46780415aa5c53b8a3dd4 |
|
BLAKE2b-256 | cbb618396e7e369e604e28f1d70a4a5b1b35e35353505ee77f8b50778b194f92 |