Skip to content

Commit accc7cb

Browse files
committed
cleanup packages and use readme template
1 parent 899d936 commit accc7cb

File tree

5 files changed

+70
-48
lines changed

5 files changed

+70
-48
lines changed

Dockerfile

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,18 @@ FROM lsiobase/nginx:3.9
33
# set version label
44
ARG BUILD_DATE
55
ARG VERSION
6+
ARG BOOKSTACK_RELEASE
67
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
78
LABEL maintainer="homerr"
89

910
# package versions
1011
ARG BOOKSTACK_RELEASE
1112

1213
RUN \
13-
echo "**** install build packages ****" && \
14+
echo "**** install packages ****" && \
1415
apk add --no-cache \
1516
curl \
16-
tar \
17+
fontconfig \
1718
memcached \
1819
netcat-openbsd \
1920
php7-ctype \
@@ -29,15 +30,10 @@ RUN \
2930
php7-phar \
3031
php7-simplexml \
3132
php7-tidy \
32-
php7-tokenizer && \
33-
echo "**** install wkhtmltopdf ****" && \
34-
apk add --no-cache \
33+
php7-tokenizer \
34+
qt5-qtbase \
35+
tar \
3536
ttf-freefont \
36-
fontconfig && \
37-
apk add --no-cache \
38-
--repository http://dl-3.alpinelinux.org/alpine/edge/testing/ \
39-
--allow-untrusted \
40-
qt5-qtbase-dev \
4137
wkhtmltopdf && \
4238
echo "**** configure php-fpm ****" && \
4339
sed -i 's/;clear_env = no/clear_env = no/g' /etc/php7/php-fpm.d/www.conf && \
@@ -46,7 +42,7 @@ RUN \
4642
mkdir -p\
4743
/var/www/html && \
4844
if [ -z ${BOOKSTACK_RELEASE+x} ]; then \
49-
BOOKSTACK_RELEASE=$(curl -sX GET "https://api.github.com/repos/bookstackapp/bookstack/releases/latest" \
45+
BOOKSTACK_RELEASE=$(curl -sX GET "https://api.github.com/repos/bookstackapp/bookstack/releases/latest" \
5046
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
5147
fi && \
5248
curl -o \

Dockerfile.aarch64

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,18 @@ FROM lsiobase/nginx:arm64v8-3.9
33
# set version label
44
ARG BUILD_DATE
55
ARG VERSION
6+
ARG BOOKSTACK_RELEASE
67
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
78
LABEL maintainer="homerr"
89

910
# package versions
1011
ARG BOOKSTACK_RELEASE
1112

1213
RUN \
13-
echo "**** install build packages ****" && \
14+
echo "**** install packages ****" && \
1415
apk add --no-cache \
1516
curl \
16-
tar \
17+
fontconfig \
1718
memcached \
1819
netcat-openbsd \
1920
php7-ctype \
@@ -29,15 +30,10 @@ RUN \
2930
php7-phar \
3031
php7-simplexml \
3132
php7-tidy \
32-
php7-tokenizer && \
33-
echo "**** install wkhtmltopdf ****" && \
34-
apk add --no-cache \
33+
php7-tokenizer \
34+
qt5-qtbase \
35+
tar \
3536
ttf-freefont \
36-
fontconfig && \
37-
apk add --no-cache \
38-
--repository http://dl-3.alpinelinux.org/alpine/edge/testing/ \
39-
--allow-untrusted \
40-
qt5-qtbase-dev \
4137
wkhtmltopdf && \
4238
echo "**** configure php-fpm ****" && \
4339
sed -i 's/;clear_env = no/clear_env = no/g' /etc/php7/php-fpm.d/www.conf && \
@@ -46,7 +42,7 @@ RUN \
4642
mkdir -p\
4743
/var/www/html && \
4844
if [ -z ${BOOKSTACK_RELEASE+x} ]; then \
49-
BOOKSTACK_RELEASE=$(curl -sX GET "https://api.github.com/repos/bookstackapp/bookstack/releases/latest" \
45+
BOOKSTACK_RELEASE=$(curl -sX GET "https://api.github.com/repos/bookstackapp/bookstack/releases/latest" \
5046
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
5147
fi && \
5248
curl -o \

Dockerfile.armhf

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,18 @@ FROM lsiobase/nginx:arm32v7-3.9
33
# set version label
44
ARG BUILD_DATE
55
ARG VERSION
6+
ARG BOOKSTACK_RELEASE
67
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
78
LABEL maintainer="homerr"
89

910
# package versions
1011
ARG BOOKSTACK_RELEASE
1112

1213
RUN \
13-
echo "**** install build packages ****" && \
14+
echo "**** install packages ****" && \
1415
apk add --no-cache \
1516
curl \
16-
tar \
17+
fontconfig \
1718
memcached \
1819
netcat-openbsd \
1920
php7-ctype \
@@ -29,15 +30,10 @@ RUN \
2930
php7-phar \
3031
php7-simplexml \
3132
php7-tidy \
32-
php7-tokenizer && \
33-
echo "**** install wkhtmltopdf ****" && \
34-
apk add --no-cache \
33+
php7-tokenizer \
34+
qt5-qtbase \
35+
tar \
3536
ttf-freefont \
36-
fontconfig && \
37-
apk add --no-cache \
38-
--repository http://dl-3.alpinelinux.org/alpine/edge/testing/ \
39-
--allow-untrusted \
40-
qt5-qtbase-dev \
4137
wkhtmltopdf && \
4238
echo "**** configure php-fpm ****" && \
4339
sed -i 's/;clear_env = no/clear_env = no/g' /etc/php7/php-fpm.d/www.conf && \
@@ -46,7 +42,7 @@ RUN \
4642
mkdir -p\
4743
/var/www/html && \
4844
if [ -z ${BOOKSTACK_RELEASE+x} ]; then \
49-
BOOKSTACK_RELEASE=$(curl -sX GET "https://api.github.com/repos/bookstackapp/bookstack/releases/latest" \
45+
BOOKSTACK_RELEASE=$(curl -sX GET "https://api.github.com/repos/bookstackapp/bookstack/releases/latest" \
5046
| awk '/tag_name/{print $4;exit}' FS='[""]'); \
5147
fi && \
5248
curl -o \

README.md

Lines changed: 35 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -144,18 +144,21 @@ In this instance `PUID=1000` and `PGID=1000`, to find yours use `id user` as bel
144144
 
145145
## Application Setup
146146

147+
147148
The default username is admin@admin.com with the password of **password**, access the container at http://dockerhost:6875.
148149

149150
This application is dependent on a MySQL database be it one you already have or a new one. If you do not already have one, set up our MariaDB container here https://hub.docker.com/r/linuxserver/mariadb/.
150151

152+
151153
If you intend to use this application behind a subfolder reverse proxy, such as our LetsEncrypt container or Traefik you will need to make sure that the `APP_URL` environment variable is set, or it will not work
152154

153155
Documentation for BookStack can be found at https://www.bookstackapp.com/docs/
154156

155157
### Advanced Users (full control over the .env file)
156-
If you wish to use the extra functionality of BookStack such as email, Memcache, LDAP and so on you will need to make your own .env file with guidance from the BookStack documentation.
158+
If you wish to use the extra functionality of BookStack such as email, memcache, ldap and so on you will need to make your own .env file with guidance from the BookStack documentation. If you wish to use the extra functionality of BookStack such as email, Memcache, LDAP and so on you will need to make your own .env file with guidance from the BookStack documentation.
159+
157160

158-
When you create the container, do not set any arguments for any SQL settings, or APP_URL. The container will copy an exemplary .env file to /config/www/.env on your host system for you to edit.
161+
When you create the container, do not set any arguments for any SQL settings, or APP_URL. The container will copy an .env file to /config/www/.env on your host system for you to edit. When you create the container, do not set any arguments for any SQL settings, or APP_URL. The container will copy an exemplary .env file to /config/www/.env on your host system for you to edit.
159162

160163
#### PDF Rendering
161164
[wkhtmltopdf](https://wkhtmltopdf.org/) is available to use as an alternative PDF rendering generator as described at https://www.bookstackapp.com/docs/admin/pdf-rendering/.
@@ -187,24 +190,45 @@ Below are the instructions for updating containers:
187190
* Start the new container: `docker start bookstack`
188191
* You can also remove the old dangling images: `docker image prune`
189192

190-
### Via Taisun auto-updater (especially useful if you don't remember the original parameters)
191-
* Pull the latest image at its tag and replace it with the same env variables in one shot:
192-
```
193-
docker run --rm \
194-
-v /var/run/docker.sock:/var/run/docker.sock taisun/updater \
195-
--oneshot bookstack
196-
```
197-
* You can also remove the old dangling images: `docker image prune`
198-
199193
### Via Docker Compose
200194
* Update all images: `docker-compose pull`
201195
* or update a single image: `docker-compose pull bookstack`
202196
* Let compose update all containers as necessary: `docker-compose up -d`
203197
* or update a single container: `docker-compose up -d bookstack`
204198
* You can also remove the old dangling images: `docker image prune`
205199

200+
### Via Watchtower auto-updater (especially useful if you don't remember the original parameters)
201+
* Pull the latest image at its tag and replace it with the same env variables in one run:
202+
```
203+
docker run --rm \
204+
-v /var/run/docker.sock:/var/run/docker.sock \
205+
containrrr/watchtower \
206+
--run-once bookstack
207+
```
208+
* You can also remove the old dangling images: `docker image prune`
209+
210+
## Building locally
211+
212+
If you want to make local modifications to these images for development purposes or just to customize the logic:
213+
```
214+
git clone https://github.com/linuxserver/docker-bookstack.git
215+
cd docker-bookstack
216+
docker build \
217+
--no-cache \
218+
--pull \
219+
-t linuxserver/bookstack:latest .
220+
```
221+
222+
The ARM variants can be built on x86_64 hardware using `multiarch/qemu-user-static`
223+
```
224+
docker run --rm --privileged multiarch/qemu-user-static:register --reset
225+
```
226+
227+
Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64`.
228+
206229
## Versions
207230

231+
* **14.06.19:** - Add wkhtmltopdf to image for PDF rendering.
208232
* **20.04.19:** - Rebase to Alpine 3.9, add MySQL init logic.
209233
* **22.03.19:** - Switching to new Base images, shift to arm32v7 tag.
210234
* **20.01.19:** - Added php7-curl

readme-vars.yml

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -77,21 +77,31 @@ custom_compose: |
7777
# application setup block
7878
app_setup_block_enabled: true
7979
app_setup_block: |
80-
Default username is admin@admin.com with password of **password**, access the container at http://dockerhost:6875.
8180
82-
This application is dependent on an MySQL database be it one you already have or a new one. If you do not already have one, set up our MariaDB container here https://hub.docker.com/r/linuxserver/mariadb/.
81+
The default username is admin@admin.com with the password of **password**, access the container at http://dockerhost:6875.
8382
83+
This application is dependent on a MySQL database be it one you already have or a new one. If you do not already have one, set up our MariaDB container here https://hub.docker.com/r/linuxserver/mariadb/.
84+
85+
8486
If you intend to use this application behind a subfolder reverse proxy, such as our LetsEncrypt container or Traefik you will need to make sure that the `APP_URL` environment variable is set, or it will not work
8587
8688
Documentation for BookStack can be found at https://www.bookstackapp.com/docs/
8789
8890
### Advanced Users (full control over the .env file)
89-
If you wish to use the extra functionality of BookStack such as email, memcache, ldap and so on you will need to make your own .env file with guidance from the BookStack documentation.
91+
If you wish to use the extra functionality of BookStack such as email, memcache, ldap and so on you will need to make your own .env file with guidance from the BookStack documentation. If you wish to use the extra functionality of BookStack such as email, Memcache, LDAP and so on you will need to make your own .env file with guidance from the BookStack documentation.
92+
93+
94+
When you create the container, do not set any arguments for any SQL settings, or APP_URL. The container will copy an .env file to /config/www/.env on your host system for you to edit. When you create the container, do not set any arguments for any SQL settings, or APP_URL. The container will copy an exemplary .env file to /config/www/.env on your host system for you to edit.
95+
96+
#### PDF Rendering
97+
[wkhtmltopdf](https://wkhtmltopdf.org/) is available to use as an alternative PDF rendering generator as described at https://www.bookstackapp.com/docs/admin/pdf-rendering/.
98+
99+
The path to wkhtmltopdf in this image to include in your .env file is `/usr/bin/wkhtmltopdf`.
90100
91-
When you create the container, do not set any arguments for any SQL settings, or APP_URL. The container will copy an .env file to /config/www/.env on your host system for you to edit.
92101
93102
# changelog
94103
changelogs:
104+
- { date: "14.06.19:", desc: "Add wkhtmltopdf to image for PDF rendering." }
95105
- { date: "20.04.19:", desc: "Rebase to Alpine 3.9, add MySQL init logic." }
96106
- { date: "22.03.19:", desc: "Switching to new Base images, shift to arm32v7 tag." }
97107
- { date: "20.01.19:", desc: "Added php7-curl"}

0 commit comments

Comments
 (0)