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)
This commit is contained in:
parent
e37d746c69
commit
26329ee584
@ -6,15 +6,15 @@ RUN useradd --create-home app \
|
||||
jq \
|
||||
git
|
||||
WORKDIR /home/app
|
||||
ARG WIKI_PACKAGE=wiki@0.13.0
|
||||
ARG WIKI_PACKAGE=wiki@0.14.0
|
||||
RUN su app -c "npm install -g --prefix . $WIKI_PACKAGE"
|
||||
RUN su app -c "mkdir .wiki"
|
||||
COPY configure-and-launch-wiki set-owner-name ./
|
||||
RUN chown app configure-and-launch-wiki set-owner-name
|
||||
COPY configure-wiki set-owner-name ./
|
||||
RUN chown app configure-wiki set-owner-name
|
||||
VOLUME "/home/app/.wiki"
|
||||
ENV DOMAIN=localhost
|
||||
ENV OWNER_NAME="The Owner"
|
||||
ENV COOKIE=insecure
|
||||
EXPOSE 3000
|
||||
USER app
|
||||
CMD ["./configure-and-launch-wiki"]
|
||||
CMD ["/home/app/bin/wiki"]
|
||||
|
11
README.md
11
README.md
@ -39,11 +39,18 @@ Let's also use a different volume for this one:
|
||||
docker volume create localtest.me
|
||||
```
|
||||
|
||||
Specify the domain name when you launch your wiki
|
||||
Specify the domain name and configure your wiki
|
||||
``` bash
|
||||
docker run -p 3000:3000 -it --rm \
|
||||
-v localtest.me:/home/app/.wiki \
|
||||
-e DOMAIN=localtest.me \
|
||||
dobbs/farm configure-wiki
|
||||
```
|
||||
|
||||
Now that configuration is complete, launch the wiki:
|
||||
``` bash
|
||||
docker run -p 3000:3000 -it --rm \
|
||||
-v localtest.me:/home/app/.wiki \
|
||||
dobbs/farm
|
||||
```
|
||||
|
||||
@ -55,7 +62,7 @@ Open http://that.localtest.me:3000 in another.
|
||||
This image's tag matches the version of the included wiki software.
|
||||
|
||||
``` bash
|
||||
git tag -am "" '0.13.0'
|
||||
git tag -am "" '0.14.0'
|
||||
git push --tags
|
||||
```
|
||||
|
||||
|
@ -7,7 +7,6 @@ main() {
|
||||
ensure-owner-file
|
||||
ensure-config-file
|
||||
show-configs
|
||||
exec-wiki
|
||||
}
|
||||
|
||||
initialize-environment-vars() {
|
||||
@ -70,8 +69,4 @@ show-configs() {
|
||||
set +x
|
||||
}
|
||||
|
||||
exec-wiki() {
|
||||
exec /home/app/bin/wiki
|
||||
}
|
||||
|
||||
main
|
Loading…
x
Reference in New Issue
Block a user