8 Commits

Author SHA1 Message Date
76280f3e7b Update wiki to 0.16.2 2019-03-11 08:00:53 -06:00
356afda8a7 Update wiki version for security fix 2018-11-27 21:10:15 -08:00
e9bd94e860 remind myself how to publish plugin experiments 2018-02-28 08:23:21 -07:00
b0be20f5f3 point to local-farm.wiki.dbbs.co instead 2018-02-25 22:32:46 -07:00
26329ee584 upgrade to wiki-0.14.0 and move configure-wiki to separate step
We should only need to run the configure-wiki script once instead of
every time we start the container.  Also, I don't think that script
was correctly handling PID 1 role (e.g. don't think we forwarded
signals to node nor reaped zombies)
2018-02-25 21:58:43 -07:00
e37d746c69 upgrade to node-8 and to wiki-0.13.0 2017-12-11 08:02:50 -07:00
86548c594a upgrade to wiki 0.12.2
includes update to client and several plugins:
calendar, markdown, and html
2017-11-06 18:00:57 -07:00
ef34fdc759 enable github-based npm packages for WIKI_PACKAGE
npm needs git installed in order to install packages from github
2017-10-02 07:10:55 -06:00
3 changed files with 30 additions and 35 deletions

View File

@ -1,19 +1,20 @@
FROM node:4-slim FROM node:8-slim
RUN useradd --create-home app \ RUN useradd --create-home app \
&& apt-get update \ && apt-get update \
&& apt-get install -y --no-install-recommends \ && apt-get install -y --no-install-recommends \
jq jq \
git
WORKDIR /home/app WORKDIR /home/app
ARG WIKI_PACKAGE=wiki@0.12.1 ARG WIKI_PACKAGE=wiki@0.16.2
RUN su app -c "npm install -g --prefix . $WIKI_PACKAGE" RUN su app -c "npm install -g --prefix . $WIKI_PACKAGE"
RUN su app -c "mkdir .wiki" RUN su app -c "mkdir .wiki"
COPY configure-and-launch-wiki set-owner-name ./ COPY configure-wiki set-owner-name ./
RUN chown app configure-and-launch-wiki set-owner-name RUN chown app configure-wiki set-owner-name
VOLUME "/home/app/.wiki" VOLUME "/home/app/.wiki"
ENV DOMAIN=localhost ENV DOMAIN=localhost
ENV OWNER_NAME="The Owner" ENV OWNER_NAME="The Owner"
ENV COOKIE=insecure ENV COOKIE=insecure
EXPOSE 3000 EXPOSE 3000
USER app USER app
CMD ["./configure-and-launch-wiki"] CMD ["/home/app/bin/wiki"]

View File

@ -2,6 +2,11 @@
http://fed.wiki.org http://fed.wiki.org
Although this container can run alone, I use and develop it with
a reverse proxy. See: https://github.com/dobbs/wiki-tls
See also http://local-farm.wiki.dbbs.co for many more details.
### Get acquainted with wiki. ### Get acquainted with wiki.
Launch the container: Launch the container:
@ -29,31 +34,25 @@ docker run -p 3000:3000 -it --rm \
Visit http://localhost:3000 Visit http://localhost:3000
### Make your wiki a local farm
We're going to use http://localtest.me instead of localhost for our
domain name. See http://readme.localtest.me for more info.
Let's also use a different volume for this one:
``` bash
docker volume create localtest.me
```
Specify the domain name when you launch your wiki
``` bash
docker run -p 3000:3000 -it --rm \
-v localtest.me:/home/app/.wiki \
-e DOMAIN=localtest.me \
dobbs/farm
```
Open http://this.localtest.me:3000 in one tab.
Open http://that.localtest.me:3000 in another.
# Development # Development
This image's tag does not match the version of the included wiki software.
Notes to self:
``` bash ``` bash
VERSION=0.12.0 git tag -am "" '0.50.0'
docker build --build-arg VERSION=$VERSION -t dobbs/farm:$VERSION . git push --tags
git tag -am "" $VERSION ```
The repos in Dockerhub and GitHub are configured to automatically build new tags.
# Publish experimental plugins
``` bash
docker build \
--tag dobbs/farm:0.14.0-frame \
--build-arg WIKI_PACKAGE='dobbs/wiki#frame' \
.
docker push dobbs/farm:0.14.0-frame
``` ```

View File

@ -7,7 +7,6 @@ main() {
ensure-owner-file ensure-owner-file
ensure-config-file ensure-config-file
show-configs show-configs
exec-wiki
} }
initialize-environment-vars() { initialize-environment-vars() {
@ -70,8 +69,4 @@ show-configs() {
set +x set +x
} }
exec-wiki() {
exec /home/app/bin/wiki
}
main main