Jump to content
jbrodriguez

[Plugin] ControlR

306 posts in this topic Last Reply

Recommended Posts

ControlR is a companion plugin for the ControlR app.

 

Screenshot

WZpK4fa.png

 

Introduction

This plugin allows you to set up user permissions for the ControlR app.

 

Operation is simple

- Add a user in the unRAID webGUI

 

- Select that user in the plugin

 

- Define permissions for the user

 

 

The following are the allowed permissions:

 

VISIBLE: If turned off, the docker/vm will not appear in the app

 

READ: User can see the docker/vm, but actions are disabled

 

WRITE:User can edit/remove the docker/vm

 

EXECUTE: User can start/stop the docker/vm

 

 

## Installation

There are 2 ways to install this application

 

- Community Applications

Go to the Apps tab

Click on the Plugins button

Look for ControlR

Click Install

 

- Plugins Tab (manual)

Go to the Plugins tab

Click on Install Plugin

Paste the following address in the input field: https://raw.githubusercontent.com/jbrodriguez/unraid/master/plugins/controlr.plg

Click Install

 

## Running the app

After installing the plugin, you can access the web UI, via the following methods:

 

- Method 1

Go to Settings > Utilities

Click on ControlR

Click on Open Web UI

 

- Method 2

Go to Plugins > Installed Plugins

Click on ControlR

Click on Open Web UI

 

- Method 3

Navigate with your browser to http://Tower:2378/ (replace Tower with the address/name of your unRAID server)

 

CHANGELOG

 

v2018.10.03 (2.14.0)


This release always starts the api endpoint on https.

 

Other changes:
- Remove $GOPATH from stack trace
- Go lint (revive)
- Fix Go lint errors

 

v2018-07-14 (2.12.0)

 

- Modify logic about which port to listen on

 

This enables redirection for the web UI side of the plugin.

 

With respect to the ControlR APP support the plugin provides, this is how you should add your server to make sure it works:

 

If the SSL setting in your unRAID is set to 

'yes' -> Add the server via ip/hostname, https port, secure switch on

'auto' -> Add the server via ip/hostname, https port, secure switch on

'no' -> Add the server via ip/hostname, http port, secure switch off 

 

This is reflected in the app's FAQ.

 

2018-07-07 - 2.11.0

- Modify logic to set listening port

 

v2018.03.21 - 2.9.2

- Add support for unRAID 6.5.0

 

v2018.02.16a (2.9.1)

This release implements a rewrite of the permissions webUI (new framework), although visually it remains mostly the same.

 

Other changes:
- Fix issue with checking permissions in UI
- Fix ipmi sensor detection

Edited by jbrodriguez
edit changelog
  • Upvote 1

Share this post


Link to post

installed v1. Unable to login as root on web interface.

 

Unable to connect to server

401 (Unauthorized)

 

root is the only user on server.

Screenshot_1.jpg.97c9611695e4f313974b947fda468e04.jpg

Share this post


Link to post

installed v1. Unable to login as root on web interface.

 

Unable to connect to server

401 (Unauthorized)

 

root is the only user on server.

 

Can you check the log (should be at /usr/local/emhttp/plugins/controlr/controlr.log) for any warnings ?

 

Send it over pm or email if you want.

 

I'll change the log location in the next release.

Share this post


Link to post

installed v1. Unable to login as root on web interface.

 

Unable to connect to server

401 (Unauthorized)

 

root is the only user on server.

 

Can you check the log (should be at /usr/local/emhttp/plugins/controlr/controlr.log) for any warnings ?

 

Send it over pm or email if you want.

 

I'll change the log location in the next release.

 

There is no *.log file in that folder.

Screenshot_1.jpg.9762822ad4c69d01a6b946e68f9345aa.jpg

Share this post


Link to post

installed v1. Unable to login as root on web interface.

 

Unable to connect to server

401 (Unauthorized)

 

root is the only user on server.

 

Can you check the log (should be at /usr/local/emhttp/plugins/controlr/controlr.log) for any warnings ?

 

Send it over pm or email if you want.

 

I'll change the log location in the next release.

 

There is no *.log file in that folder.

 

I am having the exact same problem. I cannot login: unable to connect to server 401 (unauthorized). Similar to interwebtech no log file being created.

Share this post


Link to post

Well, it wasn't logging at all  :o

 

I uploaded v1.0.1 with this change, log file is at /boot/logs/controlr.log

Share this post


Link to post

Well, it wasn't logging at all  :o

 

I uploaded v1.0.1 with this change, log file is at /boot/logs/controlr.log

 

plugin has lost its link to open web page. Manually trying to open web page, neither http://tower:2378/ or IP work at all. No logs at that location.

 

tower refused to connect.

Share this post


Link to post

Well, it wasn't logging at all  :o

 

I uploaded v1.0.1 with this change, log file is at /boot/logs/controlr.log

 

plugin has lost its link to open web page. Manually trying to open web page, neither http://tower:2378/ or IP work at all. No logs at that location.

 

tower refused to connect.

 

Following up... toggle Enable ControlR Server  setting brought link back and page opens. Log contents:

 

I: 2016/10/26 15:12:03 app.go:51: controlr v1.0.1-70.d2e1212 starting ...
I: 2016/10/26 15:12:03 app.go:59: No config file specified. Using app defaults ...
I: 2016/10/26 15:12:03 unraid.go:55: starting service Unraid ...
I: 2016/10/26 15:12:03 server.go:67: Starting service Server ...
I: 2016/10/26 15:12:03 server.go:86: Serving files from /usr/local/emhttp/plugins/controlr
I: 2016/10/26 15:12:03 server.go:125: Server started listening on :2378
I: 2016/10/26 15:12:03 app.go:81: Press Ctrl+C to stop ...
W: 2016/10/26 15:12:14 server.go:179: shadowHash != actualHash

Share this post


Link to post

Well, it wasn't logging at all  :o

 

I uploaded v1.0.1 with this change, log file is at /boot/logs/controlr.log

 

plugin has lost its link to open web page. Manually trying to open web page, neither http://tower:2378/ or IP work at all. No logs at that location.

 

tower refused to connect.

 

Following up... toggle Enable ControlR Server  setting brought link back and page opens. Log contents:

 

I: 2016/10/26 15:12:03 app.go:51: controlr v1.0.1-70.d2e1212 starting ...
I: 2016/10/26 15:12:03 app.go:59: No config file specified. Using app defaults ...
I: 2016/10/26 15:12:03 unraid.go:55: starting service Unraid ...
I: 2016/10/26 15:12:03 server.go:67: Starting service Server ...
I: 2016/10/26 15:12:03 server.go:86: Serving files from /usr/local/emhttp/plugins/controlr
I: 2016/10/26 15:12:03 server.go:125: Server started listening on :2378
I: 2016/10/26 15:12:03 app.go:81: Press Ctrl+C to stop ...
W: 2016/10/26 15:12:14 server.go:179: shadowHash != actualHash

 

Ok, that would indicate passwords don't match.

 

I'll pm you.

Share this post


Link to post

v1.0.2 is out, this should fix the authentication issue.

 

Thanks interwebtech and bmdegraaf for the report and support in debugging.

Share this post


Link to post

I am able to login but not sure if what I see is correct. I made browser narrow so it would fit in one screenshot. The red arrow points at icon that just spins ands spins with nothing happening.

 

I have no users other than root. I have no VMs. I have 4 dockers. Should I be seeing something other than this?

Screenshot_1.jpg.3847cbe381e604a4606bf3f294d38b4f.jpg

Share this post


Link to post

I am able to login but not sure if what I see is correct. I made browser narrow so it would fit in one screenshot. The red arrow points at icon that just spins ands spins with nothing happening.

 

I have no users other than root. I have no VMs. I have 4 dockers. Should I be seeing something other than this?

 

Yes, you should see the 4 dockers :)

 

Anything strange in the log ?

Share this post


Link to post

I am able to login but not sure if what I see is correct. I made browser narrow so it would fit in one screenshot. The red arrow points at icon that just spins ands spins with nothing happening.

 

I have no users other than root. I have no VMs. I have 4 dockers. Should I be seeing something other than this?

 

Yes, you should see the 4 dockers :)

 

Anything strange in the log ?

 

I see nothing about scanning for dockers or VMs. I emptied the log and restarted the plugin. This is all I get in log:

I: 2016/10/27 16:34:42 app.go:85: Received signal: (terminated) ... shutting down the app now ...
I: 2016/10/27 16:34:42 server.go:132: stopped service Server ...
I: 2016/10/27 16:34:42 unraid.go:67: stopped service Unraid ...
I: 2016/10/27 16:34:48 app.go:51: controlr v1.0.2-78.dd2e5a8 starting ...
I: 2016/10/27 16:34:48 app.go:59: No config file specified. Using app defaults ...
I: 2016/10/27 16:34:48 unraid.go:55: starting service Unraid ...
I: 2016/10/27 16:34:48 server.go:69: Starting service Server ...
I: 2016/10/27 16:34:48 server.go:88: Serving files from /usr/local/emhttp/plugins/controlr
I: 2016/10/27 16:34:48 server.go:127: Server started listening on :2378
I: 2016/10/27 16:34:48 app.go:81: Press Ctrl+C to stop ...

 

All I get is the spinner. Took a peek with Chrome tools and spotted this error in console:

websocket open
Uncaught TypeError: Cannot read property 'map' of null(…)
http://192.168.1.8:2378/app/main-c6c02c5.min.js

 

 

Share this post


Link to post

I am able to login but not sure if what I see is correct. I made browser narrow so it would fit in one screenshot. The red arrow points at icon that just spins ands spins with nothing happening.

 

I have no users other than root. I have no VMs. I have 4 dockers. Should I be seeing something other than this?

 

Yes, you should see the 4 dockers :)

 

Anything strange in the log ?

 

I see nothing about scanning for dockers or VMs. I emptied the log and restarted the plugin. This is all I get in log:

I: 2016/10/27 16:34:42 app.go:85: Received signal: (terminated) ... shutting down the app now ...
I: 2016/10/27 16:34:42 server.go:132: stopped service Server ...
I: 2016/10/27 16:34:42 unraid.go:67: stopped service Unraid ...
I: 2016/10/27 16:34:48 app.go:51: controlr v1.0.2-78.dd2e5a8 starting ...
I: 2016/10/27 16:34:48 app.go:59: No config file specified. Using app defaults ...
I: 2016/10/27 16:34:48 unraid.go:55: starting service Unraid ...
I: 2016/10/27 16:34:48 server.go:69: Starting service Server ...
I: 2016/10/27 16:34:48 server.go:88: Serving files from /usr/local/emhttp/plugins/controlr
I: 2016/10/27 16:34:48 server.go:127: Server started listening on :2378
I: 2016/10/27 16:34:48 app.go:81: Press Ctrl+C to stop ...

 

All I get is the spinner. Took a peek with Chrome tools and spotted this error in console:

websocket open
Uncaught TypeError: Cannot read property 'map' of null(…)
http://192.168.1.8:2378/app/main-c6c02c5.min.js

 

Thanks, I thought the server had crashed, but it's something client related .. I'll check.

Share this post


Link to post

v1.0.3 is available

 

2016-10-28 - 1.0.3

- Fix issue when there were no users/apps

- Cosmetic fixes to UI

- Include additional logging

 

This should fix the issue where there are no users (other than root), but there are apps available (dockers/vms).

 

Note, that in this scenario, clicking on the the checkboxes is a no-op, since it's not modifying any user.

 

root has full access to the server.

Share this post


Link to post

v1.02, just found these on console after reboot:

 

bin/bash line 3 /usr/local/emhttp/plugins/controlr/scripts/stop: no such file or directory

 

grep: /etc/php-fpm.d/www.conf: no such file or directoy

(this one twice)

Share this post


Link to post

Thanks interwebtech !

 

v1.0.4 should be available now

 

Not sure what the error is with the stop script ... I'll have to check that next

Share this post


Link to post

Thanks interwebtech !

 

v1.0.4 should be available now

 

Not sure what the error is with the stop script ... I'll have to check that next

 

When updating the plug-in, i have to turn off ControlR and then back on for the UI link to show.

 

Other than that I can see all my dockers and such now. Looks great! :)

Share this post


Link to post

Thanks interwebtech !

 

v1.0.4 should be available now

 

Not sure what the error is with the stop script ... I'll have to check that next

 

When updating the plug-in, i have to turn off ControlR and then back on for the UI link to show.

 

Other than that I can see all my dockers and such now. Looks great! :)

 

Thanks interwebtech !

 

It probably has to do with the error you mentioned, I'll check that.

Share this post


Link to post

updated to 1.06 and still have the bash error on reboot.

 

Yes, I haven't fixed that yet  :o

 

I think it has something to do with 6.2.x, since I can't see the same behaviour in 6.1.x.

 

My 6.2.x server is temporarily out of order (mobo died), so I can't troubleshoot the issue right now.

 

I'll look into it by next week.

Share this post


Link to post

v1.1.0 is out  !

 

- Create api endpoint to support ControlR app

 

This release enables support to display logs in the ControlR app.

 

Share this post


Link to post

updated to 1.06 and still have the bash error on reboot.

 

I'm unable to reproduce the error.

 

All I see is in the syslog is

Nov 10 08:56:16 hal sudo: root : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/bin/bash -c /usr/local/emhttp/plugins/controlr/controlr -port 2378

 

I tried 6.2.0 first, then 6.2.4 ... started the server, used the plugin, rebooted ... and it's there running.

 

Does the error appear in the syslog in your case ? Is it the plugin stopped ?

 

Can you check that

/boot/config/plugins/controlr/controlr.cfg

exists ?

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now