pyunraid - control Unraid using Python


simse

Recommended Posts

Hello Unraiders,

 

I've just a released a beta version of a Python module I've been working on for a while now. It's called pyunraid and allows you to communicate with your Unraid server using python. It supports Python 3.4 and up and is available to install via pip. Documentation can be found here: https://pyunraid.simse.io/docs. Pypi page is here: https://pypi.org/project/pyunraid/. Github is here: https://github.com/simse/pyunraid.

 

I'm not trying to promote myself or anything, I'd just be very happy if some of you would try it out and report any bugs, since I've only been able to test it against my own server.

 

Install using: pip install pyunraid OR python3 -m pyunraid OR pip3 install pyunraid

 

Small code sample:

from pyunraid import Unraid

# Connect to Unraid server
unraid = Unraid('192.168.0.4', USERNAME, PASSWORD)

# Get all Docker containers
containers = unraid.containers()

# Restart all containers
for container in containers:
  container.restart()
  
# Get all plugins
plugins = unraid.plugins()

# Print all plugin names
for plugin in plugins:
  print(plugin.name)

 

Edited by simse
Fixed broken docs URL
Link to comment
  • 3 months later...

Hi simse,
So far:

  • Docs link is broken (just edit your message adding a /).
  • It would be nice to have docs on our github and on the pypi website
  • What purpose did you have in mind when you designed it?

I am trying to try to access crond using it and maybe see if i can set some jobs to run on my server - will let you know how it goes.

 

Cheers

-R-

Link to comment
  • 1 year later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.