Plugin Docker

    • OMV 1.0

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • Plugin Docker

      Hi folks !

      I'm new in this community and I'm impressed by the quality of your work ! Thanks a lot, Because of you, my HP Gen8 g1610t is very nice !!!

      I've seen there are a lot of plugins for openmediavault but I would like to use docker because, some plugins don't exist yet, and it's more secure to run some app in a contenair. i want to keep Openmediavault as longer as I can working fine and follow to upgrade it without problem even if I have a lot of application installed.

      I've seen post about docker, and docker using as plugin system but I don't know if someone has made something or not ...
      So I try to generate a plugin docker repository then a docker/dockerUI plugin,

      The work is done, and there's lot of work to do, but for now I've a plugin to install docker repository and gpg keys. A plugin to install docker, dockerUi in a container but I still have some trouble to integrate the dockerUI in the openmediavault UI ...

      I think there is a lot of people here which can do that easy ... I'm still not familiar with openmediavault UI dev ...

      So I've tried to add a proxy pass rule in Nginx (another new thing for me, because a just know apache) to redirect one tab (liek in eXtplorer plugin) on dockerUI (port 9000) and have a menu inservice named docker, wwith a config page to set working directory for docker and may be some other things ... but I'm e newbee too on docker :P !

      So if someone ar interested by this and can help me to have a full working dockerUi plugin, tell me !

      For other, docker is working fine so if you want to test it, no problem to share it ! May be on OMV testing repository ??? (if you have one, else I can save it on Github!)

      Thanks
    • I was originally going to attempt a docker plugin but I don't know docker well enough and haven't had the time. I can definitely help with your plugin and we can put it in the testing repo once it is working. Can you put the code on github or somewhere else accessible? I will also have you added to the developer forum.
      omv 4.0.14 arrakis | 64 bit | 4.13 backports kernel | omvextrasorg 4.1.0
      omv-extras.org plugins source code and issue tracker - github.com/OpenMediaVault-Plugin-Developers

      Please don't PM for support... Too many PMs!
    • Thank you for your answer !

      First, you need install the OMV-extras plugin : omv-extras.org/debian/pool/mai…omvextrasorg_1.17_all.deb

      After that, you have to install kernel-3.16 and restart you OMV server.

      Here my repository github for docker repository : github.com/slobberbone/openmediavault-docker-repo
      Then my repository github for docker plugin : github.com/slobberbone/openmediavault-docker

      Here deb files : drive.google.com/folderview?id…B6ckNHRzBMNjA&usp=sharing

      Be carefull because for now, if you install the docker plugin (no problem for docker-repo), docker works, dockerUI works too, but 2 config files in /etc/nginx/openmediavault-webgui/.../openmediavault-docker-site.conf and /etc/php5/fpm/pool.d/openmediavault-docker-site.conf breaks nginx and php5-fpm config, so after OMV webgui is not reachable anymore until you rename or remove these 2 files (.conf_not_use for example) then restart nginx and php5-fbm.

      The idea is to have something similar to eXtplorer, one tab redirect on dockerUI and another one for configuration. I read, keep docker repo in source.list could be a problem in the futur, so I'll update postinst to disable it after docker installation.

      The post was edited 1 time, last by slobberbone ().

    • slobberbone wrote:

      First, you need install the OMV-extras plugin

      I think I have that installed since I wrote it and the extplorer plugin :D

      I can also add the repo to omv-extras so we don't need another plugin just to add the repo. I will try the plugin tonight.
      omv 4.0.14 arrakis | 64 bit | 4.13 backports kernel | omvextrasorg 4.1.0
      omv-extras.org plugins source code and issue tracker - github.com/OpenMediaVault-Plugin-Developers

      Please don't PM for support... Too many PMs!
    • ryecoaaron wrote:

      slobberbone wrote:

      First, you need install the OMV-extras plugin

      I think I have that installed since I wrote it and the extplorer plugin :D

      I can also add the repo to omv-extras so we don't need another plugin just to add the repo. I will try the plugin tonight.


      So you're my mentor :D ! Thanks a lot for your work !!!
      As you want ofr add the repo ... let me know if you have problem !
    • I forked the plugin into the omv github - you have permissions to change it there too. Made a few changes. Not sure if the proxy pass is working because I don't think docker is working right.

      Just a few notes:
      - Reinstallation of plugin doesn't work without removing dockerui docker
      - docker doesn't autostart after reboot, maybe a function of dockerui?
      - omv-extras with docker repos is in repo and ready
      omv 4.0.14 arrakis | 64 bit | 4.13 backports kernel | omvextrasorg 4.1.0
      omv-extras.org plugins source code and issue tracker - github.com/OpenMediaVault-Plugin-Developers

      Please don't PM for support... Too many PMs!
    • Thanks for the possibility to push on OMV repository.

      I've juste update code source and try to generate a .deb with your changes. Normaly docker was started after installation .... I think, may be because I said you to add the repository only, that you've made in OMV-extra package, but there also dependencies ... I'll check that.

      Did you do something to display dockerUI in OMV webgui ?
    • It's just a warning ... so it would be not important for the next ...

      I have a docker plugin for omv-extra working fine now, I've just a problem for redirect nasip/dockerui/ to naspi:9200/ ...
      It was ok at one time, but, I had problem after that in dockerui, when it call json, withou 9200 port ... so error 500 ...

      If a Nginx expert pass here it would be helpful ;)

      I commit my changes to have a working plugin, just the gui not reachabe from OMV wbegui without port ...
    • So after some tests, it's fully works !
      forum.openmediavault.org/index…5b0f5e92b0cc9acbdff7e4ab2
      I've commit, then you can try this deb for test : drive.google.com/open?id=0B10m…FhRX1JoVG1WQ3M&authuser=0

      After that, I would be able to add a configuration tab to manage config of docker ...

      Then we should be able to create docker-plugin like openmediavault-docker-transmissionbt, openmediavault-docker-shaarliSQL, openmediavault-docker-teampass, openmediavault-docker-owncloud, etc ...

      first question : who to manage docker-plugin dependencies, if I remove openmediavault-docker how detect all : openmediavault-docker-transmissionbt etc ... and remove it ? or just stop it ???
      Images
      • OpenMediaVault web administration interface - openmediavault.local - Mozilla Firefox_137.png

        126.08 kB, 1,920×1,055, viewed 7,022 times
    • slobberbone wrote:

      So after some tests, it's fully works !
      first question : who to manage docker-plugin dependencies, if I remove openmediavault-docker how detect all : openmediavault-docker-transmissionbt etc ... and remove it ? or just stop it ???

      apt does all that for you. If the you install the plugin, any dependency installed with that plugin will be removed when it is uninstalled. You also can't have apt-get remove/purge in postrm. lxc-docker will be removed if the plugin installed. If the plugin didn't install it, it won't be removed. You don't want to force docker's uninstallation just be cause you are removing the plugin.

      For openmediavault-docker-transmissionbt, you would make the dependency on openmediavault-docker. Then if you remove openmediavault-docker, openmediavault-docker-transmissionbt would be removed as well.

      Is docker dependent on apparmor?

      adid, patience. There is nothing in the docker repo yet. The error should be fixed though.
      omv 4.0.14 arrakis | 64 bit | 4.13 backports kernel | omvextrasorg 4.1.0
      omv-extras.org plugins source code and issue tracker - github.com/OpenMediaVault-Plugin-Developers

      Please don't PM for support... Too many PMs!

      The post was edited 1 time, last by ryecoaaron ().

    • Another point, How do you think we should manage the auto start of docker ?

      A script called in rc.d ? let the user start it manually trought DockerUI (DockerUi auto start with option : --restart=always)

      Or dockerUI always started with the option : --restart=always on docker command at the installation then let manage the start/stop manually with dockerUI, and add an option to docker to start auto after reboot/boot, docker container started before with a config in :/etc/default/docker.io which I can made in docker-plugin.

      sudo nano /etc/default/docker.io
      And change or add the following : DOCKER_OPTS="-r=true"

      This second way delegate all container docker managment to the docker plugin with dockerUI, Is it ok for you ?
    • slobberbone wrote:

      Another point, How do you think we should manage the auto start of docker ?


      We like init scripts. ;)

      Greetings
      David
      "Well... lately this forum has become support for everything except omv" [...] "And is like someone is banning Google from their browsers"

      Only two things are infinite, the universe and human stupidity, and I'm not sure about the former.


      Upload Logfile via WebGUI/CLI
      #openmediavault on freenode IRC | German & English | GMT+1
      Absolutely no Support via PM!

      I host parts of the omv-extras.org Repository, the OpenMediaVault Live Demo and the pre-built PXE Images. If you want you can take part and help covering the costs by having a look at my profile page.
    • Only real problem with DockerUI is it just isn't pretty. Functional yes, but having to remember docker containers by ID instead of a simple name kinda sucks.

      I don't want to brag about another product but the docker implementation in unRAID is foolproof.
      Images
      • Screen Shot 2015-05-02 at 12.52.17 PM.png

        273.93 kB, 1,288×855, viewed 3,941 times