You are not logged in.
Pages: 1
I have seen some Docker containers in Dockerhub (https://hub.docker.com/u/slitaz/). As I don't see any link to the Dockerfile / the script to generate those images, I experienced my own versions, e.g,
* A base image https://hub.docker.com/r/icymatter/slitaz40-minimal/ (with bash-4.2, glibc-base-2.13, tazpkg-4.9, coreutils-8.12, curl-7.23, openssl-1.0.0g and pacapt-2.3)
* An image with Ruby-187 https://hub.docker.com/r/icymatter/slitaz40-ruby187/ (I have a legacy application that uses such Ruby). This image uses the base image [c]slitaz40-minimal[/c]
The results are impressivily small. But there are many things to improve
* 64-bit version would really help to expand the use of Slitaz with Docker
* Security concerns: The packages are not signed / verified, and it's not good for general use
* It's nice if [c]tazpkg[/c] can remove some package and its dependencies (We may need some development packages, like [c]glibc-dev[/c] to build softwares, but then we need to remove them to minimize the size of Docker image)
* A problem with [c]tazpkg[/c] reported here http://forum.slitaz.org/topic/slitaz-4-tazpkg-deletes-files-if-they-are-in-two-packages
I would start new Docker images with the Slitaz-rolling-64bit.
The question is why we need to use Slitaz with Docker? There are many reasons, definitely! Docker image/ container runs on modern hardware, but the base image should be always secure, lightweight and small. Running with Ubuntu or Debian is fine, but the results image are too heavy and contain a lot of useless things.
There is Alpine Linux, which is based on [c]musl[/c] instead of [c]glibc[/c]. But they also have to build [c]glibc[/c] to support some (many?) applications. They have good use, but I also think Slitaz is good, too.
Let's see how far I can go on this. Feel free to comment and share your ideas.
Thanks for your reading.
Offline
Some images
[c]
icymatter/slitaz40-redmine09x 61.45 MB
icymatter/slitaz40-ruby187 34.02 MB
icymatter/slitaz40-btsync13 14.69 MB
icymatter/slitaz40-minimal 9.133 MB
[/c]
Offline
Script to generate base image (4.0, 5.0) https://github.com/icy/docker/blob/fluentd/baseimage/slitaz_mkimage.sh
Offline
Hi Anh,
You wrote:
[c]# FIXME:[/c]
[c]# 5.0 or rolling: 'cacerts' bundle is still out-of-date[/c]
I update the cacerts package: http://cook.slitaz.org/cooker.cgi?pkg=cacerts
Is it enough?
Check the mirrors for updates with the new cacerts package.
Offline
Thanks a lot, Aleksej.
Offline
>icymatter/slitaz40-redmine09x 61.45 MB
Thanks, just trying to explore..
[c]geev03@geev03-virtual-machine:~$ docker pull icymatter/slitaz40-redmine09x
Using default tag: latest
latest: Pulling from icymatter/slitaz40-redmine09x
ee4f124ec5cc: Pull complete
9cb284aae9f2: Pull complete
d1792b5e4bc1: Pull complete
3069913b37f3: Pull complete
d6edcf5cc3b4: Pull complete
Digest: sha256:0faac43851b56a20a79a68ce950d8c086adce21d5815c621d68c9d353e1eccfa
Status: Downloaded newer image for icymatter/slitaz40-redmine09x:latest
geev03@geev03-virtual-machine:~$ docker run icymatter/slitaz40-redmine09x ifconfig
eth0 Link encap:Ethernet HWaddr 02:42:AC:11:00:02
inet addr:172.17.0.2 Bcast:0.0.0.0 Mask:255.255.0.0
inet6 addr: fe80::42:acff:fe11:2/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1 errors:0 dropped:0 overruns:0 frame:0
TX packets:1 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:90 (90.0 B) TX bytes:90 (90.0 B)
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
geev03@geev03-virtual-machine:~$ docker run icymatter/slitaz40-redmine09x tazpkg list
List of all installed packages
================================================================================
gcc-lib-base 4.5.2 development
glibc-base 2.13 base-system
glibc-dev 2.13 development
gmp 5.0.1 development
libcrypto 1.0.0g security
libcrypto-dev 1.0.0g development
libgomp 4.5.2 development
libidn 1.21 system-tools
libmysqlclient 5.1.54 misc
libssl 1.0.0g development
mpc-library 0.8.2 development
mpfr 3.0.1 development
openssl 1.0.0g security
slitaz-base-files 4.6 base-system
zlib 1.2.6 base-system
================================================================================
15 packages installed.[/c]
Offline
[c]</p>
<p>geev03@geev03-virtual-machine:~$ docker pull icymatter/slitaz40-minimal<br />
Using default tag: latest<br />
latest: Pulling from icymatter/slitaz40-minimal<br />
b0a2d15647c8: Pull complete<br />
Digest: sha256:d579b981f1900459296acee332cce9fe8a3f12976a254ab6d6fbe8d2bd63139e<br />
Status: Downloaded newer image for icymatter/slitaz40-minimal:latest<br />
geev03@geev03-virtual-machine:~$ docker run icymatter/slitaz40-minimal tazpkg list</p>
<p>List of all installed packages<br />
================================================================================<br />
bash 4.2.53 system-tools<br />
busybox 1.18.4 base-system<br />
bzlib 1.0.6 utilities<br />
coreutils 8.12 system-tools<br />
curl 7.23.1 network<br />
gettext-base 0.18.1.1 base-system<br />
glibc-base 2.13 base-system<br />
libcrypto 1.0.0g security<br />
libcurl 7.23.1 network<br />
libidn 1.21 system-tools<br />
libssl 1.0.0g development<br />
libtaz 1.6 base-system<br />
ncurses 5.9 base-system<br />
ncurses-common 5.9 base-system<br />
openssl 1.0.0g security<br />
readline 6.2 system-tools<br />
slitaz-base-files 4.6 base-system<br />
tazpkg 4.9.2 base-system<br />
zlib 1.2.6 base-system<br />
================================================================================<br />
19 packages installed.</p>
<p>geev03@geev03-virtual-machine:~$<br />[/c]
How is it that the very small minimal system has more packages installed ?
Offline
Hello geev03,
Thank you for your report.
There was a problem with the redmine09x Dockerfile. As you can see in source file
https://github.com/icy/docker/blob/fluentd/bocker/Bockerfile.slitaz_ruby187
https://github.com/icy/docker/blob/fluentd/bocker/Bockerfile.slitaz_redmine09x
I used the [c]pacapt[/c] script to purge slitaz database and some packages are missing. I will figure out how to fix that.
Offline
Hello AnhHuynh,
Thanks for the information. I tried to install and run apache . The installation part went like this, same as in a traditional VM.
[c]</p>
<p>root@debian:/home/geev03# docker run icymatter/slitaz40-minimal tazpkg recharge</p>
<p>Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.desc 100% |*******************************| 349k --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.md5 100% |*******************************| 195k --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.txt 100% |*******************************| 274k --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.list 100% |*******************************| 61722 --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.equiv 100% |*******************************| 4116 --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
files.list.lzma 100% |*******************************| 1816k 00:00:00 ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
wget: server returned error: HTTP/1.1 416 Requested Range Not Satisfiable</p>
<p>================================================================================<br />
Last packages.list is ready to use. Note that next time you recharge the<br />
list, a list of differences will be displayed to show new and upgradeable<br />
packages.<br />
root@debian:/home/geev03# docker run icymatter/slitaz40-minimal tazpkg get-install apache</p>
<p>Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.desc 100% |*******************************| 349k --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.md5 100% |*******************************| 195k --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.txt 100% |*******************************| 274k --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.list 100% |*******************************| 61722 --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
packages.equiv 100% |*******************************| 4116 --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
files.list.lzma 100% |*******************************| 1816k --:--:-- ETA<br />
Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
wget: server returned error: HTTP/1.1 416 Requested Range Not Satisfiable</p>
<p>================================================================================<br />
Last packages.list is ready to use. Note that next time you recharge the<br />
list, a list of differences will be displayed to show new and upgradeable<br />
packages.</p>
<p>Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
apache-2.2.29.tazpkg 100% |*******************************| 586k --:--:-- ETA<br />
Tracking dependencies for : apache<br />
================================================================================<br />
Missing: apr-util<br />
Missing: apr<br />
Missing: pcre<br />
Missing: util-linux-ng-uuid<br />
Missing: expat<br />
================================================================================<br />
5 missing package(s) to install.</p>
<p>Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
apr-util-1.3.10.tazp 100% |*******************************| 42172 --:--:-- ETA<br />
Tracking dependencies for : apr-util<br />
================================================================================<br />
Missing: apr<br />
Missing: expat<br />
================================================================================<br />
2 missing package(s) to install.</p>
<p>Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
apr-1.4.2.tazpkg 100% |*******************************| 56756 --:--:-- ETA<br />
Tracking dependencies for : apr<br />
================================================================================<br />
Missing: util-linux-ng-uuid<br />
================================================================================<br />
1 missing package(s) to install.</p>
<p>Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
util-linux-ng-uuid-2 100% |*******************************| 12144 --:--:-- ETA</p>
<p>Installation of : util-linux-ng-uuid<br />
================================================================================<br />
Copying util-linux-ng-uuid... [ OK ]<br />
Extracting util-linux-ng-uuid... [ OK ]<br />
Extracting the pseudo fs... (lzma) [ OK ]<br />
Installing util-linux-ng-uuid... [ OK ]<br />
Removing all tmp files... [ OK ]<br />
================================================================================<br />
util-linux-ng-uuid (2.19.1) is installed.</p>
<p>Installation of : apr<br />
================================================================================<br />
Copying apr... [ OK ]<br />
Extracting apr... [ OK ]<br />
Extracting the pseudo fs... (lzma) [ OK ]<br />
Installing apr... [ OK ]<br />
Removing all tmp files... [ OK ]<br />
================================================================================<br />
apr (1.4.2) is installed.</p>
<p>Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
expat-2.0.1.tazpkg 100% |*******************************| 50008 --:--:-- ETA</p>
<p>Installation of : expat<br />
================================================================================<br />
Copying expat... [ OK ]<br />
Extracting expat... [ OK ]<br />
Extracting the pseudo fs... (lzma) [ OK ]<br />
Installing expat... [ OK ]<br />
Removing all tmp files... [ OK ]<br />
================================================================================<br />
expat (2.0.1) is installed.</p>
<p>Installation of : apr-util<br />
================================================================================<br />
Copying apr-util... [ OK ]<br />
Extracting apr-util... [ OK ]<br />
Extracting the pseudo fs... (lzma) [ OK ]<br />
Installing apr-util... [ OK ]<br />
Removing all tmp files... [ OK ]<br />
================================================================================<br />
apr-util (1.3.10) is installed.</p>
<p>Connecting to mirror.slitaz.org (212.83.135.187:80)<br />
Connecting to download.tuxfamily.org (88.191.250.18:80)<br />
pcre-8.20.tazpkg 100% |*******************************| 57612 --:--:-- ETA</p>
<p>Installation of : pcre<br />
================================================================================<br />
Copying pcre... [ OK ]<br />
Extracting pcre... [ OK ]<br />
Extracting the pseudo fs... (lzma) [ OK ]<br />
Installing pcre... [ OK ]<br />
Removing all tmp files... [ OK ]<br />
================================================================================<br />
pcre (8.20) is installed.</p>
<p>Installation of : apache<br />
================================================================================<br />
Copying apache... [ OK ]<br />
Extracting apache... [ OK ]<br />
Extracting the pseudo fs... (lzma) [ OK ]<br />
Processing pre-install commands...<br />
Saving configuration files for apache... [ OK ]<br />
Installing apache... [ OK ]<br />
Removing all tmp files... [ OK ]<br />
Processing post-install commands...<br />
Generating a 1024 bit RSA private key<br />
.....++++++<br />
...............++++++<br />
writing new private key to '/etc/ssl/apache/apache.pem'<br />
-----<br />
You are about to be asked to enter information that will be incorporated<br />
into your certificate request.<br />
What you are about to enter is what is called a Distinguished Name or a DN.<br />
There are quite a few fields but you can leave some blank<br />
For some fields there will be a default value,<br />
If you enter '.', the field will be left blank.<br />
-----<br />
Country Name (2 letter code) [AU]:State or Province Name (full name) [Some-State]:Locality Name (eg, city) []:Organization Name (eg, company) [Internet Widgits Pty Ltd]:Organizational Unit Name (eg, section) []:Common Name (e.g. server FQDN or YOUR name) []:Email Address []:Starting Apache Web Server: Apache... httpd: Could not reliably determine the server's fully qualified domain name, using 172.17.0.2 for ServerName<br />
[ OK ]<br />
================================================================================<br />
apache (2.2.29) is installed.</p>
<p>root@debian:/home/geev03#<br />[/c]
I only see'ERR_CONNECTION_TIMED_OUT' at http://172.17.0.2/
Is it possible to start apache ?
Offline
Hi geev03,
Within Docker container you can install and start any services. However, the init script doesn't start (as PID 1) and you need to find another way, and this is how Docker container is different from a VM.
I recommend you to refer to Docker manual for further instructions.
Thanks,
Offline
Hi AnhHuynh,
Thank you. Wonder why the same 'docker run -it xxx/yyy' that works in one slitaz image is not working in another slitaz image.
[c]<br />
root@debian:/home/geev03# docker run -it slitaz/slitaz-base<br />
root@8d6c135117bc:/# free<br />
total used free shared buffers<br />
Mem: 2044860 398236 1646624 0 17716<br />
-/+ buffers: 380520 1664340<br />
Swap: 901116 0 901116<br />
root@8d6c135117bc:/# exit<br />
root@debian:/home/geev03# docker run -it icymatter/slitaz40-minimal<br />
docker: Error response from daemon: No command specified.<br />
See 'docker run --help'.<br />[/c]
Offline
The [c]minimal[/c] image is used as the lowest layer on that you build your own PID 1. You can specify any command you want.
docker run -ti --rm icymatter/slitaz40-minimal /bin/bash
Hope this helps.
Offline
[c]
root@debian:/home/geev03# docker run -ti --rm icymatter/slitaz40-minimal /bin/bash
bash-4.2# free
total used free shared buffers
Mem: 2044860 349256 1695604 0 14944
-/+ buffers: 334312 1710548
Swap: 901116 0 901116
bash-4.2#
[/c]
Once again, thank you
Offline
Apache on 'Dockerised Slitaz'...
[c]<br />
tazpkg recharge<br />
tazpkg upgrade<br />
tazpkg get-install mc<br />
tazpkg get-install apache<br />
tazpkg get-install mysql<br />
tazpkg get-install php<br />
tazpkg get-install phpmyadmin<br />
mc<br />
cd /var/www/<br />
mv map.html index.html<br />
/etc/init.d/apache start<br />
ifconfig<br />[/c]
[attachment=43056,2337]
Offline
Hi geev03,
It's great.
You need to create new Dockerfile that builds on top of my image. For example
FROM icymatter/slitaz40-minimal
RUN tazpkg recharge && tazpkg upgrade && ...
CMD ["/etc/init.d/apache", "start"]
Note the last command. That doesn't really work, because Docker needs its PID1 program to run on the foregroud. So you need a [c]httpd-foreground[/c] version as below
* https://github.com/docker-library/httpd/blob/12bf8c8883340c98b3988a7bade8ef2d0d6dcf8a/2.2/Dockerfile (scroll to the very end of this link)
* https://github.com/docker-library/httpd/blob/12bf8c8883340c98b3988a7bade8ef2d0d6dcf8a/2.2/httpd-foreground
Offline
Docker, trying Slitaz-5 on Windows 10
[attachment=43149,2347]
Offline
@AnhHuynh,
Please check new mail!
http://forum.slitaz.org/topic/re-iron-browser?replies=3#post-43300
Offline
Pages: 1
[ Generated in 0.019 seconds, 7 queries executed - Memory usage: 1.61 MiB (Peak: 1.77 MiB) ]