diff options
author | nodiscc <nodiscc@gmail.com> | 2017-07-04 21:37:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-07-04 21:37:30 +0200 |
commit | 5b25a9635fe808bc1c4f3eee8cdf8485115da75d (patch) | |
tree | d5c46525f3c739d9c63de860427e0b3cadd688e5 /doc/Docker.html | |
parent | d5d22a6d07917865c44148ad76f43c65a929a890 (diff) | |
parent | 8bf94136e10c64496711c8f66a4f58f89c515360 (diff) | |
download | Shaarli-5b25a9635fe808bc1c4f3eee8cdf8485115da75d.tar.gz Shaarli-5b25a9635fe808bc1c4f3eee8cdf8485115da75d.tar.zst Shaarli-5b25a9635fe808bc1c4f3eee8cdf8485115da75d.zip |
Merge pull request #772 from nodiscc/rtfd
Generate HTML documentation using MkDocs
Diffstat (limited to 'doc/Docker.html')
-rw-r--r-- | doc/Docker.html | 245 |
1 files changed, 0 insertions, 245 deletions
diff --git a/doc/Docker.html b/doc/Docker.html deleted file mode 100644 index fd0dec4b..00000000 --- a/doc/Docker.html +++ /dev/null | |||
@@ -1,245 +0,0 @@ | |||
1 | <!DOCTYPE html> | ||
2 | <html> | ||
3 | <head> | ||
4 | <meta charset="utf-8"> | ||
5 | <meta name="generator" content="pandoc"> | ||
6 | <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes"> | ||
7 | <title>Shaarli – Docker</title> | ||
8 | <style type="text/css">code{white-space: pre;}</style> | ||
9 | <style type="text/css"> | ||
10 | div.sourceCode { overflow-x: auto; } | ||
11 | table.sourceCode, tr.sourceCode, td.lineNumbers, td.sourceCode { | ||
12 | margin: 0; padding: 0; vertical-align: baseline; border: none; } | ||
13 | table.sourceCode { width: 100%; line-height: 100%; } | ||
14 | td.lineNumbers { text-align: right; padding-right: 4px; padding-left: 4px; color: #aaaaaa; border-right: 1px solid #aaaaaa; } | ||
15 | td.sourceCode { padding-left: 5px; } | ||
16 | code > span.kw { color: #007020; font-weight: bold; } /* Keyword */ | ||
17 | code > span.dt { color: #902000; } /* DataType */ | ||
18 | code > span.dv { color: #40a070; } /* DecVal */ | ||
19 | code > span.bn { color: #40a070; } /* BaseN */ | ||
20 | code > span.fl { color: #40a070; } /* Float */ | ||
21 | code > span.ch { color: #4070a0; } /* Char */ | ||
22 | code > span.st { color: #4070a0; } /* String */ | ||
23 | code > span.co { color: #60a0b0; font-style: italic; } /* Comment */ | ||
24 | code > span.ot { color: #007020; } /* Other */ | ||
25 | code > span.al { color: #ff0000; font-weight: bold; } /* Alert */ | ||
26 | code > span.fu { color: #06287e; } /* Function */ | ||
27 | code > span.er { color: #ff0000; font-weight: bold; } /* Error */ | ||
28 | code > span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */ | ||
29 | code > span.cn { color: #880000; } /* Constant */ | ||
30 | code > span.sc { color: #4070a0; } /* SpecialChar */ | ||
31 | code > span.vs { color: #4070a0; } /* VerbatimString */ | ||
32 | code > span.ss { color: #bb6688; } /* SpecialString */ | ||
33 | code > span.im { } /* Import */ | ||
34 | code > span.va { color: #19177c; } /* Variable */ | ||
35 | code > span.cf { color: #007020; font-weight: bold; } /* ControlFlow */ | ||
36 | code > span.op { color: #666666; } /* Operator */ | ||
37 | code > span.bu { } /* BuiltIn */ | ||
38 | code > span.ex { } /* Extension */ | ||
39 | code > span.pp { color: #bc7a00; } /* Preprocessor */ | ||
40 | code > span.at { color: #7d9029; } /* Attribute */ | ||
41 | code > span.do { color: #ba2121; font-style: italic; } /* Documentation */ | ||
42 | code > span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */ | ||
43 | code > span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */ | ||
44 | code > span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */ | ||
45 | </style> | ||
46 | <link rel="stylesheet" href="github-markdown.css"> | ||
47 | <!--[if lt IE 9]> | ||
48 | <script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv-printshiv.min.js"></script> | ||
49 | <![endif]--> | ||
50 | </head> | ||
51 | <body> | ||
52 | <div id="local-sidebar"> | ||
53 | <ul> | ||
54 | <li><a href="Home.html">Home</a></li> | ||
55 | <li>Setup | ||
56 | <ul> | ||
57 | <li><a href="Download-and-Installation.html">Download and Installation</a></li> | ||
58 | <li><a href="Upgrade-and-migration.html">Upgrade and migration</a></li> | ||
59 | <li><a href="Server-requirements.html">Server requirements</a></li> | ||
60 | <li><a href="Server-configuration.html">Server configuration</a></li> | ||
61 | <li><a href="Server-security.html">Server security</a></li> | ||
62 | <li><a href="Shaarli-configuration.html">Shaarli configuration</a></li> | ||
63 | <li><a href="Plugins.html">Plugins</a></li> | ||
64 | </ul></li> | ||
65 | <li><a href="Docker.html">Docker</a></li> | ||
66 | <li><a href="Usage.html">Usage</a> | ||
67 | <ul> | ||
68 | <li><a href="Sharing-button.html">Sharing button</a> (bookmarklet)</li> | ||
69 | <li><a href="Browsing-and-Searching.html">Browsing and Searching</a></li> | ||
70 | <li><a href="Firefox-share.html">Firefox share</a></li> | ||
71 | <li><a href="RSS-feeds.html">RSS feeds</a></li> | ||
72 | <li><a href="REST-API.html">REST API</a></li> | ||
73 | </ul></li> | ||
74 | <li>How To | ||
75 | <ul> | ||
76 | <li><a href="Backup,-restore,-import-and-export.html">Backup, restore, import and export</a></li> | ||
77 | <li><a href="Copy-an-existing-installation-over-SSH-and-serve-it-locally.html">Copy an existing installation over SSH and serve it locally</a></li> | ||
78 | <li><a href="Create-and-serve-multiple-Shaarlis-(farm).html">Create and serve multiple Shaarlis (farm)</a></li> | ||
79 | <li><a href="Download-CSS-styles-from-an-OPML-list.html">Download CSS styles from an OPML list</a></li> | ||
80 | <li><a href="Datastore-hacks.html">Datastore hacks</a></li> | ||
81 | </ul></li> | ||
82 | <li><a href="Troubleshooting.html">Troubleshooting</a></li> | ||
83 | <li><a href="Development.html">Development</a> | ||
84 | <ul> | ||
85 | <li><a href="GnuPG-signature.html">GnuPG signature</a></li> | ||
86 | <li><a href="Coding-guidelines.html">Coding guidelines</a></li> | ||
87 | <li><a href="Directory-structure.html">Directory structure</a></li> | ||
88 | <li><a href="3rd-party-libraries.html">3rd party libraries</a></li> | ||
89 | <li><a href="Plugin-System.html">Plugin System</a></li> | ||
90 | <li><a href="Release-Shaarli.html">Release Shaarli</a></li> | ||
91 | <li><a href="Versioning-and-Branches.html">Versioning and Branches</a></li> | ||
92 | <li><a href="Security.html">Security</a></li> | ||
93 | <li><a href="Static-analysis.html">Static analysis</a></li> | ||
94 | <li><a href="Theming.html">Theming</a></li> | ||
95 | <li><a href="Unit-tests.html">Unit tests</a></li> | ||
96 | </ul></li> | ||
97 | <li>About | ||
98 | <ul> | ||
99 | <li><a href="FAQ.html">FAQ</a></li> | ||
100 | <li><a href="Community-&-Related-software.html">Community & Related software</a></li> | ||
101 | </ul></li> | ||
102 | </ul> | ||
103 | </div> | ||
104 | <h1 id="docker">Docker</h1> | ||
105 | <ul> | ||
106 | <li><a href="#docker-usage">Docker usage</a><a href=".html"></a></li> | ||
107 | <li><a href="#get-and-run-a-shaarli-image">Get and run a Shaarli image</a><a href=".html"></a></li> | ||
108 | <li><a href="#resources">Resources</a><a href=".html"></a></li> | ||
109 | </ul> | ||
110 | <h2 id="docker-usage">Docker usage</h2> | ||
111 | <h3 id="basics">Basics</h3> | ||
112 | <p>Install <a href="https://www.docker.com/">Docker</a>, by following the instructions relevant<a href=".html"></a><br /> | ||
113 | to your OS / distribution, and start the service.</p> | ||
114 | <h4 id="search-an-image-on-dockerhub">Search an image on <a href="https://hub.docker.com/">DockerHub</a><a href=".html"></a></h4> | ||
115 | <div class="sourceCode"><pre class="sourceCode bash"><code class="sourceCode bash">$ <span class="ex">docker</span> search debian | ||
116 | |||
117 | <span class="ex">NAME</span> DESCRIPTION STARS OFFICIAL AUTOMATED | ||
118 | <span class="ex">ubuntu</span> Ubuntu is a Debian-based Linux operating s... 2065 [OK][](.html) | ||
119 | <span class="ex">debian</span> Debian is a Linux distribution that<span class="st">'s comp... 603 [OK][](.html)</span> | ||
120 | <span class="st">google/debian 47 [OK][](.html)</span></code></pre></div> | ||
121 | <h4 id="show-available-tags-for-a-repository">Show available tags for a repository</h4> | ||
122 | <div class="sourceCode"><pre class="sourceCode bash"><code class="sourceCode bash">$ <span class="ex">curl</span> https://index.docker.io/v1/repositories/debian/tags <span class="kw">|</span> <span class="ex">python</span> -m json.tool | ||
123 | |||
124 | <span class="ex">%</span> Total % Received % Xferd Average Speed Time Time Time Current | ||
125 | <span class="ex">Dload</span> Upload Total Spent Left Speed | ||
126 | <span class="ex">100</span> 1283 0 1283 0 0 433 0 --:--:-- 0:00:02 --:--:-- 433</code></pre></div> | ||
127 | <p>Sample output:</p> | ||
128 | <div class="sourceCode"><pre class="sourceCode json"><code class="sourceCode json"><span class="ot">[[]</span><span class="er">(.html)</span> | ||
129 | <span class="fu">{</span> | ||
130 | <span class="dt">"layer"</span><span class="fu">:</span> <span class="st">"85a02782"</span><span class="fu">,</span> | ||
131 | <span class="dt">"name"</span><span class="fu">:</span> <span class="st">"stretch"</span> | ||
132 | <span class="fu">}</span><span class="ot">,</span> | ||
133 | <span class="fu">{</span> | ||
134 | <span class="dt">"layer"</span><span class="fu">:</span> <span class="st">"59abecbc"</span><span class="fu">,</span> | ||
135 | <span class="dt">"name"</span><span class="fu">:</span> <span class="st">"testing"</span> | ||
136 | <span class="fu">}</span><span class="ot">,</span> | ||
137 | <span class="fu">{</span> | ||
138 | <span class="dt">"layer"</span><span class="fu">:</span> <span class="st">"bf0fd686"</span><span class="fu">,</span> | ||
139 | <span class="dt">"name"</span><span class="fu">:</span> <span class="st">"unstable"</span> | ||
140 | <span class="fu">}</span><span class="ot">,</span> | ||
141 | <span class="fu">{</span> | ||
142 | <span class="dt">"layer"</span><span class="fu">:</span> <span class="st">"60c52dbe"</span><span class="fu">,</span> | ||
143 | <span class="dt">"name"</span><span class="fu">:</span> <span class="st">"wheezy"</span> | ||
144 | <span class="fu">}</span><span class="ot">,</span> | ||
145 | <span class="fu">{</span> | ||
146 | <span class="dt">"layer"</span><span class="fu">:</span> <span class="st">"c5b806fe"</span><span class="fu">,</span> | ||
147 | <span class="dt">"name"</span><span class="fu">:</span> <span class="st">"wheezy-backports"</span> | ||
148 | <span class="fu">}</span> | ||
149 | <span class="ot">]</span></code></pre></div> | ||
150 | <h4 id="pull-an-image-from-dockerhub">Pull an image from DockerHub</h4> | ||
151 | <div class="sourceCode"><pre class="sourceCode bash"><code class="sourceCode bash">$ <span class="ex">docker</span> pull repository[:tag][](.html) | ||
152 | |||
153 | $ <span class="ex">docker</span> pull debian:wheezy | ||
154 | <span class="ex">wheezy</span>: Pulling from debian | ||
155 | <span class="ex">4c8cbfd2973e</span>: Pull complete | ||
156 | <span class="ex">60c52dbe9d91</span>: Pull complete | ||
157 | <span class="ex">Digest</span>: sha256:c584131da2ac1948aa3e66468a4424b6aea2f33acba7cec0b631bdb56254c4fe | ||
158 | <span class="ex">Status</span>: Downloaded newer image for debian:wheezy</code></pre></div> | ||
159 | <h2 id="get-and-run-a-shaarli-image">Get and run a Shaarli image</h2> | ||
160 | <h3 id="dockerhub-repository">DockerHub repository</h3> | ||
161 | <p>The images can be found in the <a href="https://hub.docker.com/r/shaarli/shaarli/"><code>shaarli/shaarli</code></a><a href=".html"></a><br /> | ||
162 | repository.</p> | ||
163 | <h3 id="available-image-tags">Available image tags</h3> | ||
164 | <ul> | ||
165 | <li><code>latest</code>: master branch (tarball release)</li> | ||
166 | <li><code>stable</code>: stable branch (tarball release)</li> | ||
167 | <li><code>dev</code>: master branch (Git clone)</li> | ||
168 | </ul> | ||
169 | <p>All images rely on:</p> | ||
170 | <ul> | ||
171 | <li><a href="https://hub.docker.com/_/debian/">Debian 8 Jessie</a><a href=".html"></a></li> | ||
172 | <li><a href="http://php-fpm.org/">PHP5-FPM</a><a href=".html"></a></li> | ||
173 | <li><a href="http://nginx.org/">Nginx</a><a href=".html"></a></li> | ||
174 | </ul> | ||
175 | <h3 id="download-from-dockerhub">Download from DockerHub</h3> | ||
176 | <div class="sourceCode"><pre class="sourceCode bash"><code class="sourceCode bash">$ <span class="ex">docker</span> pull shaarli/shaarli | ||
177 | <span class="ex">latest</span>: Pulling from shaarli/shaarli | ||
178 | <span class="ex">32716d9fcddb</span>: Pull complete | ||
179 | <span class="ex">84899d045435</span>: Pull complete | ||
180 | <span class="ex">4b6ad7444763</span>: Pull complete | ||
181 | <span class="ex">e0345ef7a3e0</span>: Pull complete | ||
182 | <span class="ex">5c1dd344094f</span>: Pull complete | ||
183 | <span class="ex">6422305a200b</span>: Pull complete | ||
184 | <span class="ex">7d63f861dbef</span>: Pull complete | ||
185 | <span class="ex">3eb97210645c</span>: Pull complete | ||
186 | <span class="ex">869319d746ff</span>: Already exists | ||
187 | <span class="ex">869319d746ff</span>: Pulling fs layer | ||
188 | <span class="ex">902b87aaaec9</span>: Already exists | ||
189 | <span class="ex">Digest</span>: sha256:f836b4627b958b3f83f59c332f22f02fcd495ace3056f2be2c4912bd8704cc98 | ||
190 | <span class="ex">Status</span>: Downloaded newer image for shaarli/shaarli:latest</code></pre></div> | ||
191 | <h3 id="create-and-start-a-new-container-from-the-image">Create and start a new container from the image</h3> | ||
192 | <div class="sourceCode"><pre class="sourceCode bash"><code class="sourceCode bash"><span class="co"># map the host's :8000 port to the container's :80 port</span> | ||
193 | $ <span class="ex">docker</span> create -p 8000:80 shaarli/shaarli | ||
194 | <span class="ex">d40b7af693d678958adedfb88f87d6ea0237186c23de5c4102a55a8fcb499101</span> | ||
195 | |||
196 | <span class="co"># launch the container in the background</span> | ||
197 | $ <span class="ex">docker</span> start d40b7af693d678958adedfb88f87d6ea0237186c23de5c4102a55a8fcb499101 | ||
198 | <span class="ex">d40b7af693d678958adedfb88f87d6ea0237186c23de5c4102a55a8fcb499101</span> | ||
199 | |||
200 | <span class="co"># list active containers</span> | ||
201 | $ <span class="ex">docker</span> ps | ||
202 | <span class="ex">CONTAINER</span> ID IMAGE COMMAND CREATED STATUS PORTS NAMES | ||
203 | <span class="ex">d40b7af693d6</span> shaarli/shaarli /usr/bin/supervisor 15 seconds ago Up 4 seconds 0.0.0.0:8000-<span class="op">></span>80/tcp backstabbing_galileo</code></pre></div> | ||
204 | <h3 id="stop-and-destroy-a-container">Stop and destroy a container</h3> | ||
205 | <div class="sourceCode"><pre class="sourceCode bash"><code class="sourceCode bash">$ <span class="ex">docker</span> stop backstabbing_galileo # those docker guys are really rude to physicists! | ||
206 | <span class="ex">backstabbing_galileo</span> | ||
207 | |||
208 | <span class="co"># check the container is stopped</span> | ||
209 | $ <span class="ex">docker</span> ps | ||
210 | <span class="ex">CONTAINER</span> ID IMAGE COMMAND CREATED STATUS PORTS NAMES | ||
211 | |||
212 | <span class="co"># list ALL containers</span> | ||
213 | $ <span class="ex">docker</span> ps -a | ||
214 | <span class="ex">CONTAINER</span> ID IMAGE COMMAND CREATED STATUS PORTS NAMES | ||
215 | <span class="ex">d40b7af693d6</span> shaarli/shaarli /usr/bin/supervisor 5 minutes ago Exited (0) <span class="ex">48</span> seconds ago backstabbing_galileo | ||
216 | |||
217 | <span class="co"># destroy the container</span> | ||
218 | $ <span class="ex">docker</span> rm backstabbing_galileo # let<span class="st">'s put an end to these barbarian practices</span> | ||
219 | <span class="st">backstabbing_galileo</span> | ||
220 | |||
221 | <span class="st">$ docker ps -a</span> | ||
222 | <span class="st">CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES</span></code></pre></div> | ||
223 | <h2 id="resources">Resources</h2> | ||
224 | <h3 id="docker-1">Docker</h3> | ||
225 | <ul> | ||
226 | <li><a href="https://www.katacoda.com/courses/docker/">Interactive Docker training portal</a> on <a href="https://www.katacoda.com/">Katakoda</a><a href=".html"></a></li> | ||
227 | <li><a href="http://blog.thoward37.me/articles/where-are-docker-images-stored/">Where are Docker images stored?</a><a href=".html"></a></li> | ||
228 | <li><a href="https://docs.docker.com/reference/builder/">Dockerfile reference</a><a href=".html"></a></li> | ||
229 | <li><a href="https://docs.docker.com/articles/dockerfile_best-practices/">Dockerfile best practices</a><a href=".html"></a></li> | ||
230 | <li><a href="https://docs.docker.com/userguide/dockervolumes/">Volumes</a><a href=".html"></a></li> | ||
231 | </ul> | ||
232 | <h3 id="dockerhub">DockerHub</h3> | ||
233 | <ul> | ||
234 | <li><a href="https://docs.docker.com/userguide/dockerrepos/">Repositories</a><a href=".html"></a></li> | ||
235 | <li><a href="https://docs.docker.com/docker-hub/orgs/">Teams and organizations</a><a href=".html"></a></li> | ||
236 | <li><a href="https://docs.docker.com/docker-hub/github/">GitHub automated build</a><a href=".html"></a></li> | ||
237 | </ul> | ||
238 | <h3 id="service-management">Service management</h3> | ||
239 | <ul> | ||
240 | <li><a href="https://docs.docker.com/articles/using_supervisord/">Using supervisord</a><a href=".html"></a></li> | ||
241 | <li><a href="http://nginx.org/en/docs/ngx_core_module.html#daemon">Nginx in the foreground</a><a href=".html"></a></li> | ||
242 | <li><a href="http://supervisord.org/">supervisord</a><a href=".html"></a></li> | ||
243 | </ul> | ||
244 | </body> | ||
245 | </html> | ||