July 3, 201511 yr I would like to create a Docker for this project: https://github.com/thoukydides/heatmiser-wifi - at the moment I have it running in a VM based on Ubuntu Server 14 which seems like a huge overkill for something simple as this. However, I never built a Docker before but am eager to learn. From what I understand I need a base image, then get the required stuff from the above link working (Git, Pearl, Pearl Packages, Upstart) inside the image, then use other Dockers for the database (MariaDB) and web server (Apache) and finally make all of them work together nicely. Is there a guide on how best to do this to make it work on unRAID? Or a general easy to follow guide on how to build a Docker like this from scratch? Any help would be very much appreciated, thanks a lot.
July 3, 201511 yr personally, i'd put the apache element and the app itself in one container, use a mariadb or mysql container for the database element, and don't use upstart in a container..
July 6, 201511 yr Author Thanks very much, that's a good idea. Any other tips on how to start, like which base image to use? Does it have to be Ubuntu-based, or would any of the other (smaller) ones would work better? Is there a guide specifically for unRAID or can I gust follow any guide on building a Docker image?
July 6, 201511 yr personally, i'd put the apache element and the app itself in one container, use a mariadb or mysql container for the database element, and don't use upstart in a container.. This. Also for baseimage look at phusion\baseimage.
July 6, 201511 yr Thanks very much, that's a good idea. Any other tips on how to start, like which base image to use? Does it have to be Ubuntu-based, or would any of the other (smaller) ones would work better? Is there a guide specifically for unRAID or can I gust follow any guide on building a Docker image? There are some 'best practices' appearing on these forums for unRAID Dockers but I can't for the life of me figure why they'd want to depart from the standard Docker thinking. As I keep saying, Docker is just a packaging mechanism and is completely platform agnostic (or should be if done right). Basically what I'm saying is, any Docker guide will do. Docker is Docker, even on unRAID.
July 6, 201511 yr Docker is Docker, even on unRAID. That is essentially true, but there are certains things that if implemented can make a docker more suitable for unraid, uid and gid being the main one, using the TZ variable (passed with the bind time feature from the template) in containers where timezones are important is another, although the TZ variable can be passed manually from the comnand line of course on non-unraid boxes.
July 6, 201511 yr Docker is Docker, even on unRAID. That is essentially true, but there are certains things that if implemented can make a docker more suitable for unraid, uid and gid being the main one, using the TZ variable (passed with the bind time feature from the template) in containers where timezones are important is another, although the TZ variable can be passed manually from the comnand line of course on non-unraid boxes. If you're building a container you're on the command line anyway...
July 6, 201511 yr Docker is Docker, even on unRAID. That is essentially true, but there are certains things that if implemented can make a docker more suitable for unraid, uid and gid being the main one, using the TZ variable (passed with the bind time feature from the template) in containers where timezones are important is another, although the TZ variable can be passed manually from the comnand line of course on non-unraid boxes. If you're building a container you're on the command line anyway... if you're the only person using it.......
July 6, 201510 yr Author personally, i'd put the apache element and the app itself in one container, use a mariadb or mysql container for the database element, and don't use upstart in a container.. If I can't use UPSTART in a container, what should I do to run a daemon instead?
July 6, 201510 yr personally, i'd put the apache element and the app itself in one container, use a mariadb or mysql container for the database element, and don't use upstart in a container.. If I can't use UPSTART in a container, what should I do to run a daemon instead? runit (if you're going with phusion baseimage or supervisor if you're not, or if the app and runit don't get on together) sometimes to get the command to use in either (and this doesn't always work) i edit the upstart or init file and change the exec in the exec line to echo and run it from a command line inside the container.
July 6, 201510 yr And how do I get my own Docker container loaded into my unRAID system? depends if you want to share it or just use it yourself (selfish, lol) make a git repository for the dockerfile and ancillary files like startup routines and config files etc..... then use dockerhub automated build linked to that repo. then make a template repo and an xml file for it container repo example https://github.com/sparklyballs/docker-containers template repo example https://github.com/sparklyballs/docker-repo/tree/templates/Sparklys-Repo announce the repo in the main docker thread and squid will pick it up and put it in the community applications plugin and his thread on repos. BUT if you're going to be selfish, lol.... just do the build on your unraid box and you'll get a docker image appear in your docker tab, providing you've setup a docker.img file
July 6, 201510 yr To continue with Sparkly's comments -> if you don't want to share it, you can still make the github repo and the template and add the repository as a private one (and have CA still manage it) -> see the OP in the CA thread
March 6, 20188 yr On 7/6/2015 at 2:39 PM, sparklyballs said: just do the build on your unraid box and you'll get a docker image appear in your docker tab, providing you've setup a docker.img file So...for the docker inept (outside of using CA to get and install dockers) can you explain how to do the build on unraid? Do I need to navigate to a specific folder? Any specific commands to get the image where it's supposed to be? Can you explain more about "providing you've setup a docker.img file"? Is that the one that exists on the system if I'm using dockers or will that be a docker image for the docker file I'm building?
March 6, 20188 yr 20 minutes ago, NeoMatrixJR said: So...for the docker inept (outside of using CA to get and install dockers) can you explain how to do the build on unraid? Do I need to navigate to a specific folder? Any specific commands to get the image where it's supposed to be? Can you explain more about "providing you've setup a docker.img file"? Is that the one that exists on the system if I'm using dockers or will that be a docker image for the docker file I'm building? Been a while since I played with any of this, but everything docker related the unRAID webUI and its plugins do is just commands to the builtin docker engine. That docker engine has everything you need to build dockers. It is documented extensively at the docker website. https://www.docker.com/ Go to the command line and start playing around.
April 2, 20206 yr Since this is the first thread that comes up on google and isn't very detailed, I just wanted to link the guide I just wrote. It shows you how to create a docker container, add it to your own private docker registry (or you can use dockerhub), and then add it to the private apps section of Community Applications.
March 22, 20215 yr On 7/6/2015 at 8:39 PM, sparklyballs said: just do the build on your unraid box and you'll get a docker image appear in your docker tab, providing you've setup a docker.img file this comment is pur gold.. thank you.. this works for me..
Archived
This topic is now archived and is closed to further replies.