Crash when reloading rockons pages after modifying my locally created rockon

Brief description of the problem

Problem after uninstalling a rock-on, the GUI believes that it is still uninstalled or something like that and throws an error.

Detailed step by step instructions to reproduce the problem

Using my own made mldonkey rock-on,
1- unistalled it from rockstor gui
2- modified the .json file to change one port from 4001 to 4000
3- removed the docker images as the repo is just updated and wanted to pull it from it to test the whole cycle. The current image was locally created (with its own Dockerfiles et al)
4- Reloaded the available images list and then this error started to appear every time I hit update in both rockon screen, the one with the installed rockons and the one with the available ones. It’s not loading my new rockon either.

Web-UI screenshot

Error Traceback provided on the Web-UI

Traceback (most recent call last): File "/opt/rockstor/src/rockstor/storageadmin/views/rockon.py", line 105, in post self._create_update_meta(r, rockons[r]) File "/opt/rockstor/eggs/Django-1.6.11-py2.7.egg/django/db/transaction.py", line 371, in inner return func(*args, **kwargs) File "/opt/rockstor/src/rockstor/storageadmin/views/rockon.py", line 214, in _create_update_meta handle_exception(Exception(e_msg), self.request) File "/opt/rockstor/src/rockstor/storageadmin/util.py", line 49, in handle_exception raise RockStorAPIException(detail=e_msg, trace=traceback.format_exc()) RockStorAPIException: ['Cannot add/remove port definitions of the container(mldonkey) as it belongs to an installed Rock-on(MLDonkey). Uninstall it first and try again.', 'Traceback (most recent call last):\n File "/opt/rockstor/eggs/gunicorn-0.16.1-py2.7.egg/gunicorn/workers/sync.py", line 34, in run\n client, addr = self.socket.accept()\n File "/usr/lib64/python2.7/socket.py", line 202, in accept\n sock, addr = self._sock.accept()\nerror: [Errno 11] Resource temporarily unavailable\n']

Try to remove it by cli.
“docker rm container“
“docker rmi image“
Then install it as you tried

Hi @Mark93

That’s exactly what I did in step 3, my bad that I didn’t detailed it enough… I’ve fixed it with the following steps, so anyone tinckering with its own rockons can follow in case this happens:
1- Deleted the updated .json file from /opt/rockstor/rockons-metastore/
2- Updated the rock-ons page, now it worked fine and MLDonkey dissapeared as an available Rock-on as it should
3- Copied back the .json file for my rock-on in /opt/rockstor/rockons-metastore/ and updated rock-ons page again. This time it worked and my rock-on was ready for install again
4 - Tried to install it, all the configuration screens went fine but in the last step it failed…

OK, checking the logs I found out that it was trying to delete the mldonkey container, which I had already done from the shell, so back to the shell, made a docker pull angeletor/mldonkey, updated the rock-ons page just in case and tried to reinstall and this last time it worked flawlessly.

I don’t know if the GUI doesn’t remove the docker container intentionally until the reinstall, and when I deleted it from the CLI I messed its internal workings, or it’s some sort of bug. I just wanted to be sure to pull the latest version from my repo.

Sorry for the long post, just wanted to detail the process so the developers have an exact idea of what happened. Now everything’s working fine and I’m back into testing shipyard