add documentation

This commit is contained in:
Wonderfall 2017-08-27 18:05:49 +02:00
parent 6ddfe1b7c6
commit 98d0cd925d
28 changed files with 286 additions and 1127 deletions

View File

@ -0,0 +1,35 @@
## wonderfall/cryptpad
The Zero Knowledge Cloud.
#### Features
- Based on Alpine Linux
- Bundled with latest node.js available.
#### Build-time variables
- **VERSION** : version of Cryptpad
#### Environment variables
- **UID** : user id *(default : 991)*
- **GID** : group id *(default : 991)*
#### Volumes
- **/cryptpad/datastore** : Cryptpad data
- **/cryptpad/customize** : Cryptpad custom files
#### Ports
- **3000** [(reverse proxy!)](https://github.com/hardware/mailserver/wiki/Reverse-proxy-configuration)
#### docker-compose.yml sample
```
cryptpad:
image: wonderfall/cryptpad
container_name: cryptpad
environment:
- UID=1444
- GID=1444
volumes:
- /mnt/docker/cryptpad/files:/cryptpad/datastore
- /mnt/docker/cryptpad/customize:/cryptpad/customize
```

View File

@ -1,67 +0,0 @@
FROM alpine:3.6
ARG GHOST_VERSION=0.11.11
ENV GHOST_NODE_VERSION_CHECK=false \
GID=991 \
UID=991 \
DOMAIN=my-ghost-blog.com \
SSL=False \
SYNTAX_HIGHLIGHTING=False \
HIGHLIGHTER_COLOR=light \
CUSTOM_SMTP=False \
SMTP_HOST=mail.domain.tld \
SMTP_PASS=123456 \
SMTP_USER=user \
SMTP_PORT=587 \
SMTP_SENDER_MAIL=user@domain.tld \
SMTP_SENDER_NAME=Ghost \
ENABLE_ISSO=False \
ISSO_HOST=isso.domain.tld \
ISSO_AVATAR=false \
ISSO_VOTE=false \
ENABLE_DISQUS=False \
DISQUS_SHORTNAME=shortname
VOLUME /ghost/content
RUN echo "@commuedge https://nl.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories \
&& apk -U add \
libressl \
ca-certificates \
bash \
grep \
tini@commuedge \
su-exec \
nodejs-current \
nodejs-current-npm \
&& wget -q https://github.com/TryGhost/Ghost/releases/download/${GHOST_VERSION}/Ghost-${GHOST_VERSION}.zip -P /tmp \
&& unzip -q /tmp/Ghost-${GHOST_VERSION}.zip -d /ghost \
&& cd /ghost \
&& npm install --production \
&& mv content/themes/casper casper \
&& mv config.example.js config.js \
&& sed -i 's/127.0.0.1/0.0.0.0/g' config.js \
&& npm cache clean \
&& rm -rf /tmp/* /var/cache/apk/*
COPY run.sh /usr/local/bin/run.sh
COPY smtp.conf /usr/local/etc/smtp.conf
COPY isso.conf /usr/local/etc/isso.conf
COPY disqus.conf /usr/local/etc/disqus.conf
COPY prism_light.js /ghost/prismjs/light/prism.js
COPY prism_light.css /ghost/prismjs/light/prism.css
COPY prism_dark.js /ghost/prismjs/dark/prism.js
COPY prism_dark.css /ghost/prismjs/dark/prism.css
COPY prism.js.conf /usr/local/etc/prism.js.conf
COPY prism.css.conf /usr/local/etc/prism.css.conf
RUN chmod +x /usr/local/bin/run.sh
EXPOSE 2368
LABEL description="Ghost CMS ready for production" \
ghost="Ghost v$VERSION" \
maintainer="Wonderfall <wonderfall@targaryen.house>"
CMD ["run.sh"]

View File

@ -1,35 +0,0 @@
## wonderfall/ghost
![](https://i.goopics.net/lt.png)
#### What is this? What features?
- A **simple** Ghost CMS build made for production.
- It is based on Alpine Linux so it's lightweight.
- It uses node.js LTS (version check is disabled).
- Environment variables, thus providing basic flexibility.
- Offers Isso and Disqus basic support (casper).
- Offers syntax highlighting using [prism.js](http://prismjs.com/) (casper).
#### Build-time variables
- **VERSION** : version of Ghost.
#### Environment variables
- **GID** : ghost user id *(default : 991)*
- **UID** : ghost group id *(default : 991)*
- **SSL** : set to *True* if you use *https* on your blog. *(default : False)*
- **DOMAIN** : your domain (without *http(s)://*) *(default : my-ghost-blog.com)*
- **SYNTAX_HIGHLIGHTING** : enables syntax highlighting if set to *True* *(default : False)*
- **HIGHLIGHTER_COLOR** : color of syntax highlighting, *light* or *dark* *(default : light)*
- **CUSTOM_SMTP** : enables SMTP if set to *True* *(default : False)*
- **SMTP_PORT**, **SMTP_USER**, **SMTP_HOST** : SMTP settings
- **SMTP\_SENDER\_MAIL**, **SMTP\_SENDER\_NAME** : other SMTP settings
- **ENABLE_ISSO** : enables Isso support if set to *True* *(default : False)*
- **ISSO_HOST**, **ISSO_AVATAR**, **ISSO_VOTE** : Isso settings
- **ENABLE_DISQUS** : enables Disqus if set to *True* *(default : False)*
- **DISQUS_SHORTNAME** : your Disqus shortname
#### Volumes
- **/ghost/content** : contents of your blog, including themes
### Ports
- **2368** [(reverse proxy!)](https://github.com/hardware/mailserver/wiki/Reverse-proxy-configuration)

View File

@ -1,8 +0,0 @@
<script data-isso="//<HOST>/"
data-isso-avatar="<AVATAR>"
data-isso-vote="<VOTE>"
src="//<HOST>/js/embed.min.js"></script>
<section id="isso-thread"></section>

View File

@ -1 +0,0 @@
<link rel="stylesheet" type="text/css" href="{{asset "css/prism.css"}}" />

View File

@ -1 +0,0 @@
<script type="text/javascript" src="{{asset "js/prism.js"}}"></script>

View File

@ -1,289 +0,0 @@
/* http://prismjs.com/download.html?themes=prism-okaidia&languages=markup+css+clike+javascript+abap+actionscript+ada+apacheconf+apl+applescript+asciidoc+aspnet+autoit+autohotkey+bash+basic+batch+c+brainfuck+bro+bison+csharp+cpp+coffeescript+ruby+css-extras+d+dart+django+diff+docker+eiffel+elixir+erlang+fsharp+fortran+gherkin+git+glsl+go+graphql+groovy+haml+handlebars+haskell+haxe+http+icon+inform7+ini+j+jade+java+jolie+json+julia+keyman+kotlin+latex+less+livescript+lolcode+lua+makefile+markdown+matlab+mel+mizar+monkey+nasm+nginx+nim+nix+nsis+objectivec+ocaml+oz+parigp+parser+pascal+perl+php+php-extras+powershell+processing+prolog+properties+protobuf+puppet+pure+python+q+qore+r+jsx+reason+rest+rip+roboconf+crystal+rust+sas+sass+scss+scala+scheme+smalltalk+smarty+sql+stylus+swift+tcl+textile+twig+typescript+verilog+vhdl+vim+wiki+xojo+yaml&plugins=autolinker+file-highlight+toolbar+highlight-keywords+previewer-base+previewer-color+command-line+data-uri-highlight+show-language+copy-to-clipboard */
/**
* okaidia theme for JavaScript, CSS and HTML
* Loosely based on Monokai textmate theme by http://www.monokai.nl/
* @author ocodia
*/
code[class*="language-"],
pre[class*="language-"] {
color: #f8f8f2;
background: none;
text-shadow: 0 1px rgba(0, 0, 0, 0.3);
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
text-align: left;
white-space: pre;
word-spacing: normal;
word-break: normal;
word-wrap: normal;
line-height: 1.5;
-moz-tab-size: 4;
-o-tab-size: 4;
tab-size: 4;
-webkit-hyphens: none;
-moz-hyphens: none;
-ms-hyphens: none;
hyphens: none;
}
/* Code blocks */
pre[class*="language-"] {
padding: 1em;
overflow: auto;
border-radius: 0.3em;
}
:not(pre) > code[class*="language-"],
pre[class*="language-"] {
background: #272822;
}
/* Inline code */
:not(pre) > code[class*="language-"] {
padding: .1em;
border-radius: .3em;
white-space: normal;
}
.token.comment,
.token.prolog,
.token.doctype,
.token.cdata {
color: slategray;
}
.token.punctuation {
color: #f8f8f2;
}
.namespace {
opacity: .7;
}
.token.property,
.token.tag,
.token.constant,
.token.symbol,
.token.deleted {
color: #f92672;
}
.token.boolean,
.token.number {
color: #ae81ff;
}
.token.selector,
.token.attr-name,
.token.string,
.token.char,
.token.builtin,
.token.inserted {
color: #a6e22e;
}
.token.operator,
.token.entity,
.token.url,
.language-css .token.string,
.style .token.string,
.token.variable {
color: #f8f8f2;
}
.token.atrule,
.token.attr-value,
.token.function {
color: #e6db74;
}
.token.keyword {
color: #66d9ef;
}
.token.regex,
.token.important {
color: #fd971f;
}
.token.important,
.token.bold {
font-weight: bold;
}
.token.italic {
font-style: italic;
}
.token.entity {
cursor: help;
}
.token a {
color: inherit;
}
pre.code-toolbar {
position: relative;
}
pre.code-toolbar > .toolbar {
position: absolute;
top: .3em;
right: .2em;
transition: opacity 0.3s ease-in-out;
opacity: 0;
}
pre.code-toolbar:hover > .toolbar {
opacity: 1;
}
pre.code-toolbar > .toolbar .toolbar-item {
display: inline-block;
}
pre.code-toolbar > .toolbar a {
cursor: pointer;
}
pre.code-toolbar > .toolbar button {
background: none;
border: 0;
color: inherit;
font: inherit;
line-height: normal;
overflow: visible;
padding: 0;
-webkit-user-select: none; /* for button */
-moz-user-select: none;
-ms-user-select: none;
}
pre.code-toolbar > .toolbar a,
pre.code-toolbar > .toolbar button,
pre.code-toolbar > .toolbar span {
color: #bbb;
font-size: .8em;
padding: 0 .5em;
background: #f5f2f0;
background: rgba(224, 224, 224, 0.2);
box-shadow: 0 2px 0 0 rgba(0,0,0,0.2);
border-radius: .5em;
}
pre.code-toolbar > .toolbar a:hover,
pre.code-toolbar > .toolbar a:focus,
pre.code-toolbar > .toolbar button:hover,
pre.code-toolbar > .toolbar button:focus,
pre.code-toolbar > .toolbar span:hover,
pre.code-toolbar > .toolbar span:focus {
color: inherit;
text-decoration: none;
}
.prism-previewer,
.prism-previewer:before,
.prism-previewer:after {
position: absolute;
pointer-events: none;
}
.prism-previewer,
.prism-previewer:after {
left: 50%;
}
.prism-previewer {
margin-top: -48px;
width: 32px;
height: 32px;
margin-left: -16px;
opacity: 0;
-webkit-transition: opacity .25s;
-o-transition: opacity .25s;
transition: opacity .25s;
}
.prism-previewer.flipped {
margin-top: 0;
margin-bottom: -48px;
}
.prism-previewer:before,
.prism-previewer:after {
content: '';
position: absolute;
pointer-events: none;
}
.prism-previewer:before {
top: -5px;
right: -5px;
left: -5px;
bottom: -5px;
border-radius: 10px;
border: 5px solid #fff;
box-shadow: 0 0 3px rgba(0, 0, 0, 0.5) inset, 0 0 10px rgba(0, 0, 0, 0.75);
}
.prism-previewer:after {
top: 100%;
width: 0;
height: 0;
margin: 5px 0 0 -7px;
border: 7px solid transparent;
border-color: rgba(255, 0, 0, 0);
border-top-color: #fff;
}
.prism-previewer.flipped:after {
top: auto;
bottom: 100%;
margin-top: 0;
margin-bottom: 5px;
border-top-color: rgba(255, 0, 0, 0);
border-bottom-color: #fff;
}
.prism-previewer.active {
opacity: 1;
}
.prism-previewer-color {
background-image: linear-gradient(45deg, #bbb 25%, transparent 25%, transparent 75%, #bbb 75%, #bbb), linear-gradient(45deg, #bbb 25%, #eee 25%, #eee 75%, #bbb 75%, #bbb);
background-size: 10px 10px;
background-position: 0 0, 5px 5px;
}
.prism-previewer-color:before {
background-color: inherit;
background-clip: padding-box;
}
.command-line-prompt {
border-right: 1px solid #999;
display: block;
float: left;
font-size: 100%;
letter-spacing: -1px;
margin-right: 1em;
pointer-events: none;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.command-line-prompt > span:before {
color: #999;
content: ' ';
display: block;
padding-right: 0.8em;
}
.command-line-prompt > span[data-user]:before {
content: "[" attr(data-user) "@" attr(data-host) "] $";
}
.command-line-prompt > span[data-user="root"]:before {
content: "[" attr(data-user) "@" attr(data-host) "] #";
}
.command-line-prompt > span[data-prompt]:before {
content: attr(data-prompt);
}

File diff suppressed because one or more lines are too long

View File

@ -1,305 +0,0 @@
/* http://prismjs.com/download.html?themes=prism&languages=markup+css+clike+javascript+abap+actionscript+ada+apacheconf+apl+applescript+asciidoc+aspnet+autoit+autohotkey+bash+basic+batch+c+brainfuck+bro+bison+csharp+cpp+coffeescript+ruby+css-extras+d+dart+django+diff+docker+eiffel+elixir+erlang+fsharp+fortran+gherkin+git+glsl+go+graphql+groovy+haml+handlebars+haskell+haxe+http+icon+inform7+ini+j+jade+java+jolie+json+julia+keyman+kotlin+latex+less+livescript+lolcode+lua+makefile+markdown+matlab+mel+mizar+monkey+nasm+nginx+nim+nix+nsis+objectivec+ocaml+oz+parigp+parser+pascal+perl+php+php-extras+powershell+processing+prolog+properties+protobuf+puppet+pure+python+q+qore+r+jsx+reason+rest+rip+roboconf+crystal+rust+sas+sass+scss+scala+scheme+smalltalk+smarty+sql+stylus+swift+tcl+textile+twig+typescript+verilog+vhdl+vim+wiki+xojo+yaml&plugins=autolinker+file-highlight+toolbar+highlight-keywords+previewer-base+previewer-color+command-line+data-uri-highlight+show-language+copy-to-clipboard */
/**
* prism.js default theme for JavaScript, CSS and HTML
* Based on dabblet (http://dabblet.com)
* @author Lea Verou
*/
code[class*="language-"],
pre[class*="language-"] {
color: black;
background: none;
text-shadow: 0 1px white;
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
text-align: left;
white-space: pre;
word-spacing: normal;
word-break: normal;
word-wrap: normal;
line-height: 1.5;
-moz-tab-size: 4;
-o-tab-size: 4;
tab-size: 4;
-webkit-hyphens: none;
-moz-hyphens: none;
-ms-hyphens: none;
hyphens: none;
}
pre[class*="language-"]::-moz-selection, pre[class*="language-"] ::-moz-selection,
code[class*="language-"]::-moz-selection, code[class*="language-"] ::-moz-selection {
text-shadow: none;
background: #b3d4fc;
}
pre[class*="language-"]::selection, pre[class*="language-"] ::selection,
code[class*="language-"]::selection, code[class*="language-"] ::selection {
text-shadow: none;
background: #b3d4fc;
}
@media print {
code[class*="language-"],
pre[class*="language-"] {
text-shadow: none;
}
}
/* Code blocks */
pre[class*="language-"] {
padding: 1em;
overflow: auto;
}
:not(pre) > code[class*="language-"],
pre[class*="language-"] {
background: #f5f2f0;
}
/* Inline code */
:not(pre) > code[class*="language-"] {
padding: .1em;
border-radius: .3em;
white-space: normal;
}
.token.comment,
.token.prolog,
.token.doctype,
.token.cdata {
color: slategray;
}
.token.punctuation {
color: #999;
}
.namespace {
opacity: .7;
}
.token.property,
.token.tag,
.token.boolean,
.token.number,
.token.constant,
.token.symbol,
.token.deleted {
color: #905;
}
.token.selector,
.token.attr-name,
.token.string,
.token.char,
.token.builtin,
.token.inserted {
color: #690;
}
.token.operator,
.token.entity,
.token.url,
.language-css .token.string,
.style .token.string {
color: #a67f59;
background: hsla(0, 0%, 100%, .5);
}
.token.atrule,
.token.attr-value,
.token.keyword {
color: #07a;
}
.token.function {
color: #DD4A68;
}
.token.regex,
.token.important,
.token.variable {
color: #e90;
}
.token.important,
.token.bold {
font-weight: bold;
}
.token.italic {
font-style: italic;
}
.token.entity {
cursor: help;
}
.token a {
color: inherit;
}
pre.code-toolbar {
position: relative;
}
pre.code-toolbar > .toolbar {
position: absolute;
top: .3em;
right: .2em;
transition: opacity 0.3s ease-in-out;
opacity: 0;
}
pre.code-toolbar:hover > .toolbar {
opacity: 1;
}
pre.code-toolbar > .toolbar .toolbar-item {
display: inline-block;
}
pre.code-toolbar > .toolbar a {
cursor: pointer;
}
pre.code-toolbar > .toolbar button {
background: none;
border: 0;
color: inherit;
font: inherit;
line-height: normal;
overflow: visible;
padding: 0;
-webkit-user-select: none; /* for button */
-moz-user-select: none;
-ms-user-select: none;
}
pre.code-toolbar > .toolbar a,
pre.code-toolbar > .toolbar button,
pre.code-toolbar > .toolbar span {
color: #bbb;
font-size: .8em;
padding: 0 .5em;
background: #f5f2f0;
background: rgba(224, 224, 224, 0.2);
box-shadow: 0 2px 0 0 rgba(0,0,0,0.2);
border-radius: .5em;
}
pre.code-toolbar > .toolbar a:hover,
pre.code-toolbar > .toolbar a:focus,
pre.code-toolbar > .toolbar button:hover,
pre.code-toolbar > .toolbar button:focus,
pre.code-toolbar > .toolbar span:hover,
pre.code-toolbar > .toolbar span:focus {
color: inherit;
text-decoration: none;
}
.prism-previewer,
.prism-previewer:before,
.prism-previewer:after {
position: absolute;
pointer-events: none;
}
.prism-previewer,
.prism-previewer:after {
left: 50%;
}
.prism-previewer {
margin-top: -48px;
width: 32px;
height: 32px;
margin-left: -16px;
opacity: 0;
-webkit-transition: opacity .25s;
-o-transition: opacity .25s;
transition: opacity .25s;
}
.prism-previewer.flipped {
margin-top: 0;
margin-bottom: -48px;
}
.prism-previewer:before,
.prism-previewer:after {
content: '';
position: absolute;
pointer-events: none;
}
.prism-previewer:before {
top: -5px;
right: -5px;
left: -5px;
bottom: -5px;
border-radius: 10px;
border: 5px solid #fff;
box-shadow: 0 0 3px rgba(0, 0, 0, 0.5) inset, 0 0 10px rgba(0, 0, 0, 0.75);
}
.prism-previewer:after {
top: 100%;
width: 0;
height: 0;
margin: 5px 0 0 -7px;
border: 7px solid transparent;
border-color: rgba(255, 0, 0, 0);
border-top-color: #fff;
}
.prism-previewer.flipped:after {
top: auto;
bottom: 100%;
margin-top: 0;
margin-bottom: 5px;
border-top-color: rgba(255, 0, 0, 0);
border-bottom-color: #fff;
}
.prism-previewer.active {
opacity: 1;
}
.prism-previewer-color {
background-image: linear-gradient(45deg, #bbb 25%, transparent 25%, transparent 75%, #bbb 75%, #bbb), linear-gradient(45deg, #bbb 25%, #eee 25%, #eee 75%, #bbb 75%, #bbb);
background-size: 10px 10px;
background-position: 0 0, 5px 5px;
}
.prism-previewer-color:before {
background-color: inherit;
background-clip: padding-box;
}
.command-line-prompt {
border-right: 1px solid #999;
display: block;
float: left;
font-size: 100%;
letter-spacing: -1px;
margin-right: 1em;
pointer-events: none;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.command-line-prompt > span:before {
color: #999;
content: ' ';
display: block;
padding-right: 0.8em;
}
.command-line-prompt > span[data-user]:before {
content: "[" attr(data-user) "@" attr(data-host) "] $";
}
.command-line-prompt > span[data-user="root"]:before {
content: "[" attr(data-user) "@" attr(data-host) "] #";
}
.command-line-prompt > span[data-prompt]:before {
content: attr(data-prompt);
}

File diff suppressed because one or more lines are too long

View File

@ -1,60 +0,0 @@
#!/bin/bash
cd /ghost/content
mkdir apps data images themes
sed -i "s|http://my-ghost-blog.com|https://$DOMAIN|g" /ghost/config.js
if [ "$SSL" == "True" ] && ! grep -q 'urlSSL' /ghost/config.js; then
sed -i "/url/a \ \ \ \ \ \ \ \ urlSSL: 'https://$DOMAIN'," /ghost/config.js
fi
if [ "$CUSTOM_SMTP" == "True" ]; then
cd /usr/local/etc
sed -i -e "/mail: {},/r smtp.conf" \
-e "/mail: {},/d" /ghost/config.js
sed -i -e "s/<HOST>/$SMTP_HOST/g" \
-e "s/<PORT>/$SMTP_PORT/g" \
-e "s/<USER>/$SMTP_USER/g" \
-e "s/<PASS>/$SMTP_PASS/g" \
-e "s/<SENDER_MAIL>/$SMTP_SENDER_MAIL/g" \
-e "s/<SENDER_NAME>/$SMTP_SENDER_NAME/g" /ghost/config.js
fi
if [ ! -d /ghost/content/themes/casper ]; then
cp -r /ghost/casper /ghost/content/themes/casper
else
CASPER=`md5sum /ghost/casper/package.json | awk '{ print $1 }'`
INSTALLED_CASPER=`md5sum /ghost/content/themes/casper/package.json | awk '{ print $1 }'`
if [ "$CASPER" != "$INSTALLED_CASPER" ]; then
rm -rf /ghost/content/themes/casper
cp -r /ghost/casper /ghost/content/themes/casper
fi
fi
if [ "$ENABLE_ISSO" == "True" ] && ! grep -q 'isso' /ghost/content/themes/casper/post.hbs; then
cd /usr/local/etc
sed -i -e "/\/author/r isso.conf" /ghost/content/themes/casper/post.hbs
sed -i -e "s/<HOST>/$ISSO_HOST/g" \
-e "s/<AVATAR>/$ISSO_AVATAR/g" \
-e "s/<VOTE>/$ISSO_VOTE/g" /ghost/content/themes/casper/post.hbs
fi
if [ "$ENABLE_DISQUS" == "True" ] && ! grep -q 'disqus' /ghost/content/themes/casper/post.hbs; then
cd /usr/local/etc
sed -i -e "/\/author/r disqus.conf" /ghost/content/themes/casper/post.hbs
sed -i -e "s/<SHORTNAME>/$DISQUS_SHORTNAME/g" /ghost/content/themes/casper/post.hbs
fi
if [ "$SYNTAX_HIGHLIGHTING" == "True" ] && [ ! -f /ghost/content/themes/casper/assets/js/prism.js ]; then
cp /ghost/prismjs/$HIGHLIGHTER_COLOR/prism.css /ghost/content/themes/casper/assets/css
cp /ghost/prismjs/$HIGHLIGHTER_COLOR/prism.js /ghost/content/themes/casper/assets/js
cd /usr/local/etc
sed -i -e "/Styles'n'Scripts/r prism.css.conf" \
-e "/The main JavaScript file for Casper/r prism.js.conf" \
/ghost/content/themes/casper/default.hbs
fi
cd /ghost
mv core fix && mv fix core && mv node_modules fix && mv fix node_modules # fix strange bug
chown -R $UID:$GID /ghost
exec su-exec $UID:$GID /sbin/tini -- npm start --production

View File

@ -1,14 +0,0 @@
mail: {
transport: 'SMTP',
from: '"<SENDER_NAME>" <<SENDER_MAIL>>',
options: {
host: '<HOST>',
port: '<PORT>',
auth: {
user: '<USER>',
pass: '<PASS>'
}
}
},

View File

@ -1,16 +0,0 @@
<div id="disqus_thread"></div>
<script type="text/javascript">
var disqus_shortname = '<SHORTNAME>';
var disqus_identifier = '{{post.id}}';
/* * * DON'T EDIT BELOW THIS LINE * * */
(function() {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
})();
</script>
<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>

View File

@ -9,9 +9,7 @@ ENV GHOST_NODE_VERSION_CHECK=false \
ENABLE_ISSO=False \ ENABLE_ISSO=False \
ISSO_HOST=isso.domain.tld \ ISSO_HOST=isso.domain.tld \
ISSO_AVATAR=false \ ISSO_AVATAR=false \
ISSO_VOTE=false \ ISSO_VOTE=false
ENABLE_DISQUS=False \
DISQUS_SHORTNAME=shortname
WORKDIR /ghost WORKDIR /ghost

44
ghost/README.md Normal file
View File

@ -0,0 +1,44 @@
## wonderfall/ghost
![](https://i.goopics.net/lt.png)
**Breaking changes if you're upgrading from 0.x. Please export your current data, and import them again in a new 1.x blog. You also have to move your images to the new volume if you want to keep them. Disqus is also not supported, please move to Isso, a much better comments system. Sorry for the mess!**
#### What is this? What features?
- A **simple** Ghost CMS build made for production.
- Based on Alpine Linux so it's lightweight!
- Bundled with latest node.js available (version check is disabled).
- Offers Isso integration.
#### Build-time variables
- **VERSION** : version of Ghost.
#### Environment variables
- **GID** : ghost user id *(default : 991)*
- **UID** : ghost group id *(default : 991)*
- **ADDRESS** : your domain (with *http(s)://*) *(default : https://my-ghost-blog.com)*
- **ENABLE_ISSO** : enables Isso support if set to *True* *(default : False)*
- **ISSO_HOST**, **ISSO_AVATAR**, **ISSO_VOTE** : Isso settings (*True* or *False*)
#### Volumes
- **/ghost/content** : contents of your blog
### Ports
- **2368** [(reverse proxy!)](https://github.com/hardware/mailserver/wiki/Reverse-proxy-configuration)
### How to configure?
Everything you need is in `/ghost/content/ghost.conf` (also mounted on your host...).
### docker-compose.yml sample
```
ghost-myblog:
image: wonderfall/ghost:1
container_name: ghost-myblog
environment:
- UID=8100
- GID=8100
- ADDRESS=https://myblog.com
volumes:
- /mnt/docker/myblog:/ghost/content
```

View File

@ -36,16 +36,6 @@ if [ "$ENABLE_ISSO" == "True" ] && ! grep -q 'isso' /ghost/content/themes/casper
-e "s/<VOTE>/$ISSO_VOTE/g" /ghost/content/themes/casper/post.hbs -e "s/<VOTE>/$ISSO_VOTE/g" /ghost/content/themes/casper/post.hbs
fi fi
if [ "$ENABLE_DISQUS" == "True" ] && grep -q 'Disqus comments' /ghost/content/themes/casper/post.hbs; then
### This is crap, if you have a better idea, tell me!
vim -e - /ghost/content/themes/casper/post.hbs <<@@@
g/site-id/.-5,.d
wq
@@@
sed -i '87d' /ghost/content/themes/casper/post.hbs
sed -i -e "s/test-apkdzgmqhj/${DISQUS_SHORTNAME}/g" /ghost/content/themes/casper/post.hbs
fi
echo "> Updating permissions..." echo "> Updating permissions..."
chown -R ${UID}:${GID} /ghost /etc/s6.d chown -R ${UID}:${GID} /ghost /etc/s6.d

69
mediawiki/README.md Normal file
View File

@ -0,0 +1,69 @@
## wonderfall/mediawiki
Host your own Wiki!
#### Features
- Based on Alpine Linux (wonderfall/nginx-php image)
- Bundled with nginx and PHP7.1.
#### Build-time variables
- **MEDIAWIKI_VER** : Mediawiki version
- **SUB_VERSION** : Mediawiki subversion
#### Environment variables
- **UID** : privatebin user id
- **GID** : privatebin group id
- **MEMORY_LIMIT** : php memorny limit *(default : 128M)*
- **UPLOAD_MAX_SIZE** : maximum upload size *(default : 10M)*
#### Volumes
- /mediawiki/images
- /extensions
- /skins
- /config
- /mediawiki/custom
#### Ports
- **8888** [(reverse proxy!)](https://github.com/hardware/mailserver/wiki/Reverse-proxy-configuration)
#### docker-compose.yml sample
```
mywiki:
image: wonderfall/mediawiki
container_name: mywiki
links:
- mywiki-db:mywiki-db
- mywiki-parsoid:mywiki-parsoid
environment:
- UPLOAD_MAX_SIZE=20M
- MEMORY_LIMIT=512M
- UID=1668
- GID=1668
volumes:
- /mnt/mywiki/images:/mediawiki/images
- /mnt/mywiki/extensions:/extensions
- /mnt/mywiki/skins:/skins
- /mnt/mywiki/config:/config
- /mnt/mywiki/custom:/mediawiki/custom
mywiki-db:
image: mariadb:10.1
container_name: mywiki-db
volumes:
- /mnt/mywiki/db:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=supersecret
- MYSQL_DATABASE=mywiki
- MYSQL_USER=mywiki
- MYSQL_PASSWORD=supersecret
mywiki-parsoid:
image: wonderfall/parsoid
container_name: mywiki-parsoid
environment:
- UID=1669
- GID=1669
- ADDRESS=https://wiki.domain.com/
- DOMAIN=mywiki-parsoid
```

28
parsoid/README.md Normal file
View File

@ -0,0 +1,28 @@
## wonderfall/parsoid
#### What is this? What features?
- A **simple** Parsoid image.
- Based on Alpine Linux so it's lightweight!
- Bundled with latest node.js available (version check is disabled).
#### Build-time variables
- **VERSION** : version of Ghost.
#### Environment variables
- **GID** : ghost user id *(default : 991)*
- **UID** : ghost group id *(default : 991)*
- **ADDRESS** : your address *(default : http://localhost/w/)*
- **DOMAIN** : name of the container *(default : localhost)*
### docker-compose.yml sample
```
mywiki-parsoid:
image: wonderfall/parsoid
container_name: mywiki-parsoid
environment:
- UID=1669
- GID=1669
- ADDRESS=https://wiki.domain.com/
- DOMAIN=mywiki-parsoid
```

View File

@ -1,5 +1,7 @@
FROM alpine:3.6 FROM alpine:3.6
ARG VERSION=0.12.0
ENV BASE_URL=False IMAGE_PROXY=False \ ENV BASE_URL=False IMAGE_PROXY=False \
UID=991 GID=991 UID=991 GID=991
@ -21,9 +23,9 @@ RUN apk -U upgrade \
openssl \ openssl \
tini \ tini \
py2-pip \ py2-pip \
&& pip install --no-cache -r https://raw.githubusercontent.com/asciimoo/searx/master/requirements.txt \
&& mkdir /usr/local/searx && cd /usr/local/searx \ && mkdir /usr/local/searx && cd /usr/local/searx \
&& wget -qO- https://github.com/asciimoo/searx/archive/master.tar.gz | tar xz --strip 1 \ && wget -qO- https://github.com/asciimoo/searx/archive/v${VERSION}.tar.gz | tar xz --strip 1 \
&& pip install --no-cache -r requirements.txt \
&& sed -i "s/127.0.0.1/0.0.0.0/g" searx/settings.yml \ && sed -i "s/127.0.0.1/0.0.0.0/g" searx/settings.yml \
&& apk del build-dependencies \ && apk del build-dependencies \
&& rm -f /var/cache/apk/* && rm -f /var/cache/apk/*

View File

@ -11,6 +11,9 @@ It provides basic privacy by mixing your queries with searches on other platform
- Latest code from [asciimoo/searx](https://github.com/asciimoo/searx) - Latest code from [asciimoo/searx](https://github.com/asciimoo/searx)
- A unique secret key is generated when booting the first time. - A unique secret key is generated when booting the first time.
#### Build-time variables
- **VERSION** : Searx version
#### Environment variables #### Environment variables
- **IMAGE_PROXY** : enables images proxying *(default : False)* - **IMAGE_PROXY** : enables images proxying *(default : False)*
- **BASE_URL** : http://domain.tld *(default : False)* - **BASE_URL** : http://domain.tld *(default : False)*

View File

@ -0,0 +1,68 @@
FROM alpine:edge
ARG TOR_VERSION=0.2.9.10
ARG ARM_VERSION=1.4.5.0
ARG GPG_Mathewson="2133 BC60 0AB1 33E1 D826 D173 FE43 009C 4607 B1FB"
ARG GPG_Johnson="6827 8CC5 DD2D 1E85 C4E4 5AD9 0445 B7AB 9ABB EEC6"
ENV TERM=xterm \
UID=991 GID=991
RUN echo "@community https://nl.alpinelinux.org/alpine/v3.4/community" >> /etc/apk/repositories \
&& BUILD_DEPS=" \
libevent-dev \
libressl-dev \
zlib-dev \
build-base \
gnupg \
ca-certificates" \
&& apk -U upgrade && apk add \
${BUILD_DEPS} \
su-exec \
tini@community \
python \
libevent \
libressl \
zlib \
&& cd /tmp \
&& TOR_TARBALL="tor-${TOR_VERSION}.tar.gz" \
&& wget -q https://www.torproject.org/dist/${TOR_TARBALL} \
&& echo "Verifying ${TOR_TARBALL} using GPG..." \
&& wget -q https://www.torproject.org/dist/${TOR_TARBALL}.asc \
&& gpg --keyserver pool.sks-keyservers.net --recv-keys 0xFE43009C4607B1FB \
&& FINGERPRINT="$(LANG=C gpg --verify ${TOR_TARBALL}.asc ${TOR_TARBALL} 2>&1 \
| sed -n "s#Primary key fingerprint: \(.*\)#\1#p")" \
&& if [ -z "${FINGERPRINT}" ]; then echo "Warning! Invalid GPG signature!" && exit 1; fi \
&& if [ "${FINGERPRINT}" != "${GPG_Mathewson}" ]; then echo "Warning! Wrong GPG fingerprint!" && exit 1; fi \
&& echo "All seems good, now unpacking ${TOR_TARBALL}..." \
&& tar xzf ${TOR_TARBALL} && cd tor-${TOR_VERSION} \
&& ./configure --disable-asciidoc && make && make install \
&& cd /tmp \
&& ARM_TARBALL="arm-${ARM_VERSION}.tar.bz2" \
&& wget -q https://www.atagar.com/arm/resources/static/${ARM_TARBALL} \
&& echo "Verifying ${ARM_TARBALL}..." \
&& wget -q https://www.atagar.com/arm/resources/static/${ARM_TARBALL}.asc \
&& gpg --keyserver pgp.mit.edu --recv-keys 0x9ABBEEC6 \
&& FINGERPRINT="$(LANG=C gpg --verify ${ARM_TARBALL}.asc ${ARM_TARBALL} 2>&1 \
| sed -n "s#Primary key fingerprint: \(.*\)#\1#p")" \
&& if [ -z "${FINGERPRINT}" ]; then echo "Warning! Invalid GPG signature!" && exit 1; fi \
&& if [ "${FINGERPRINT}" != "${GPG_Johnson}" ]; then echo "Warning! Wrong GPG fingerprint!" && exit 1; fi \
&& echo "All seems good, now unpacking ${ARM_TARBALL}..." \
&& tar xjf /tmp/${ARM_TARBALL} && cd arm && ./install \
&& apk del ${BUILD_DEPS} \
&& rm -rf /var/cache/apk/* /tmp/* /root/.gnupg
COPY run.sh /usr/local/bin/run.sh
RUN chmod +x /usr/local/bin/run.sh
VOLUME /tor/config /tor/data
EXPOSE 9001 9030
LABEL tor="Tor $TOR_VERSION" \
arm="Arm $ARM_VERSION" \
maintainer="Wonderfall <wonderfall@targaryen.house>"
ENTRYPOINT ["run.sh"]

View File

@ -0,0 +1,31 @@
## wonderfall/tor
![](https://upload.wikimedia.org/wikipedia/commons/thumb/1/15/Tor-logo-2011-flat.svg/612px-Tor-logo-2011-flat.svg.png)
#### Features
- Based on Alpine Linux.
- Tor built from source.
- ARM included, allowing real-time monitoring.
#### Usages
- As a relay ([french article](https://wonderfall.xyz/un-relais-tor-avec-docker/)).
- As a hidden service dir.
### Build-time variables
- **TOR_VERSION** : version of Tor.
- **TOR_USER_ID** : tor user id *(default : 45553)*
- **ARM_VERSION** : version of ARM
- **GPG_** : fingerprints of signing keys
#### Environment variables
- **TERM** = xterm (ARM requirement)
- **UID** = tor user id
- **GID** = tor group id
#### Volumes
- **/tor/config** : tor configuration files.
- **/tor/data** : tor data.
#### Ports
- **9001** (bind it) : ORPort.
- **9030** (bind it) : DirPort.

3
unmaintained/tor/run.sh Normal file
View File

@ -0,0 +1,3 @@
#!/bin/sh
chown -R $UID:$GID /tor
exec su-exec $UID:$GID tini -- tor $@