# Instalação e Configuração Bookstack docker

# Installation Bookstack LS

Link: [https://www.bookstackapp.com/docs/admin/installation/#docker](https://www.bookstackapp.com/docs/admin/installation/#docker)

## Docker Containers

Community docker setups are available for those that would prefer to use a containerised version of BookStack:

#### LinuxServer.io

- [GitHub Repository](https://github.com/linuxserver/docker-bookstack)
- [GitHub container package](https://github.com/linuxserver/docker-bookstack/pkgs/container/bookstack)
- [Example compose stack](https://codeberg.org/bookstack/devops/src/branch/main/config/lsio-docker/docker-compose.yml)

#### solidnerd

- [GitHub Repository](https://github.com/solidnerd/docker-bookstack)
- [Docker Hub page](https://hub.docker.com/r/solidnerd/bookstack/)

Example compose stack - LinuxServer.io

\---

\# This is an example complete example docker-compose.yml  
\# file for a linuxserver.io based BookStack setup  
\# using the linuxserver.io MariaDB conatiner.

\# ENSURE YOU PAY ATTENTION TO ALL COMMENTS BELOW.  
\# Many of the values are just examples, and you WILL  
\# have to make changes to suit your environment.

\# These containers are maintained by the linuxserver.io  
\# team, not the official BookStack project.

\# For non-commented options, refer to the linuxserver documentation:   
\# https://docs.linuxserver.io/images/docker-bookstack/#environment-variables-e

services:

 # The container for BookStack itself  
 bookstack:  
 # You should update the version here to match the latest  
 # release of BookStack: https://github.com/BookStackApp/BookStack/releases  
 # You'll change this when wanting to update the version of BookStack used.  
 image: lscr.io/linuxserver/bookstack:version-v25.02  
 container\_name: bookstack  
 environment:  
\- PUID=1000  
\- PGID=1000  
\- TZ=Etc/UTC  
 # APP\_URL must be set as the base URL you'd expect to access BookStack  
 # on via the browser. The default shown here is what you might use if accessing  
 # direct from the browser on the docker host, hence the use of the port as configured below.  
\- APP\_URL=http://localhost:6875  
 # APP\_KEY must be a unique key. Generate your own by running  
 # docker run -it --rm --entrypoint /bin/bash lscr.io/linuxserver/bookstack:latest appkey  
 # You should keep the "base64:" part for the option value.  
\- APP\_KEY=base64:3qjlIoUX4Tw6fUQgZcxMbz6lb8+dAzqpvItqHvahW1c=

 # The below database details are purposefully aligned with those  
 # configuted for the "mariadb" service below:  
\- DB\_HOST=mariadb  
\- DB\_PORT=3306  
\- DB\_DATABASE=bookstack  
\- DB\_USERNAME=bookstack  
\- DB\_PASSWORD=bookstack8432  
 volumes:  
 # You generally only ever need to map this one volume.  
 # This maps it to a "bookstack\_app\_data" folder in the same  
 # directory as this compose config file.  
\- ./bookstack\_app\_data:/config  
 ports:  
 # This exposes port 6875 for general web access.  
 # Commonly you'd have a reverse proxy in front of this,  
 # redirecting incoming requests to this port.  
\- 6875:80  
 restart: unless-stopped

 # The container for the database which BookStack will use to store  
 # most of its core data/content.  
 mariadb:  
 # You should update the version here to match the latest  
 # main version of the linuxserver mariadb container version:  
 # https://github.com/linuxserver/docker-mariadb/pkgs/container/mariadb/versions?filters%5Bversion\_type%5D=tagged  
 image: lscr.io/linuxserver/mariadb:11.4.4  
 container\_name: mariadb  
 environment:  
\- PUID=1000  
\- PGID=1000  
\- TZ=Etc/UTC  
 # You may want to change the credentials used below,  
 # but be aware the latter three options need to align  
 # with the DB\_\* options for the BookStack container.  
\- MYSQL\_ROOT\_PASSWORD=mysupersecretrootpassword  
\- MYSQL\_DATABASE=bookstack  
\- MYSQL\_USER=bookstack  
\- MYSQL\_PASSWORD=bookstack8432  
 volumes:  
 # You generally only ever need to map this one volume.  
 # This maps it to a "bookstack\_db\_data" folder in the same  
 # directory as this compose config file.  
\- ./bookstack\_db\_data:/config

 # These ports are commented out as you don't really need this port  
 # exposed for normal use, mainly only if connecting direct the the  
 # database externally. Otherwise, this risks exposing access to the  
 # database when not needed.  
 # ports:  
 # - 3306:3306  
 restart: unless-stopped

# Install Bookstack Github

Link: [https://github.com/linuxserver/docker-bookstack](https://github.com/linuxserver/docker-bookstack)

git clone [https://github.com/linuxserver/docker-bookstack.git](https://github.com/linuxserver/docker-bookstack.git)

[![linuxserver.io](https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/linuxserver_medium.png)](https://linuxserver.io/)

[![Blog](https://camo.githubusercontent.com/21fa2422bf0e66e7d4ecefb6b3077d7b17c0a417eba76be3ae1ea60e9ebaff28/68747470733a2f2f696d672e736869656c64732e696f2f7374617469632f76312e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d6c696e75787365727665722e696f266d6573736167653d426c6f67)](https://blog.linuxserver.io/ "all the things you can do with our containers including How-To guides, opinions and much more!") [![Discord](https://camo.githubusercontent.com/e195fdfb1b45ecf2d8eae50e2d58f4ef2474b2b62a7f6b7b253d9a5ec383f5aa/68747470733a2f2f696d672e736869656c64732e696f2f646973636f72642f3335343937343931323631333434393733302e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d446973636f7264266c6f676f3d646973636f7264)](https://linuxserver.io/discord "realtime support / chat with the community and the team.") [![Discourse](https://camo.githubusercontent.com/611c8e0c8170badbbf4100df147b03684a5765c721b0e961611b52887ff8d5c4/68747470733a2f2f696d672e736869656c64732e696f2f646973636f757273652f68747470732f646973636f757273652e6c696e75787365727665722e696f2f746f706963732e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6f676f3d646973636f75727365)](https://discourse.linuxserver.io/ "post on our community forum.") [![Fleet](https://camo.githubusercontent.com/99029864efbd0d5f4b0bf3ed149a60b9f7eb6ac933b85e0d88c0339af580b08a/68747470733a2f2f696d672e736869656c64732e696f2f7374617469632f76312e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d6c696e75787365727665722e696f266d6573736167653d466c656574)](https://fleet.linuxserver.io/ "an online web interface which displays all of our maintained images.") [![GitHub](https://camo.githubusercontent.com/21653ad746081dfa6c704bc566de0eabca06e005cabf347a17a4caf5b3fa562d/68747470733a2f2f696d672e736869656c64732e696f2f7374617469632f76312e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d6c696e75787365727665722e696f266d6573736167653d476974487562266c6f676f3d676974687562)](https://github.com/linuxserver "view the source for all of our repositories.") [![Open Collective](https://camo.githubusercontent.com/2cda5a201ab8adab3231e4ea4909e32fa96672f52febb975631a1b6a57d150be/68747470733a2f2f696d672e736869656c64732e696f2f6f70656e636f6c6c6563746976652f616c6c2f6c696e75787365727665722e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d537570706f7274657273266c6f676f3d6f70656e253230636f6c6c656374697665)](https://opencollective.com/linuxserver "please consider helping us by either donating or contributing to our budget")

The [LinuxServer.io](https://linuxserver.io/) team brings you another container release featuring:

- regular and timely application updates
- easy user mappings (PGID, PUID)
- custom base image with s6 overlay
- weekly base OS updates with common layers across the entire LinuxServer.io ecosystem to minimise space usage, down time and bandwidth
- regular security updates

Find us at:

- [Blog](https://blog.linuxserver.io/) - all the things you can do with our containers including How-To guides, opinions and much more!
- [Discord](https://linuxserver.io/discord) - realtime support / chat with the community and the team.
- [Discourse](https://discourse.linuxserver.io/) - post on our community forum.
- [Fleet](https://fleet.linuxserver.io/) - an online web interface which displays all of our maintained images.
- [GitHub](https://github.com/linuxserver) - view the source for all of our repositories.
- [Open Collective](https://opencollective.com/linuxserver) - please consider helping us by either donating or contributing to our budget

# [linuxserver/bookstack](https://github.com/linuxserver/docker-bookstack)

<div class="markdown-heading" dir="auto" id="bkmrk--1" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#linuxserverbookstack)</div>[![Scarf.io pulls](https://camo.githubusercontent.com/2fd05a48e383293b2d6926dc8e76b3986899e6b9d1f38ccf800a2cc8e3c08819/68747470733a2f2f73636172662e73682f696e7374616c6c732d62616467652f6c696e75787365727665722d63692f6c696e7578736572766572253246626f6f6b737461636b3f636f6c6f723d393433393864266c6162656c2d636f6c6f723d353535353535266c6f676f2d636f6c6f723d666666666666267374796c653d666f722d7468652d6261646765267061636b6167652d747970653d646f636b6572)](https://scarf.sh/) [![GitHub Stars](https://camo.githubusercontent.com/656036a0783ed40457360eda8cac883f866ae6c6677bdd0d2c828eb4bcb91620/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f6c696e75787365727665722f646f636b65722d626f6f6b737461636b2e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6f676f3d676974687562)](https://github.com/linuxserver/docker-bookstack) [![GitHub Release](https://camo.githubusercontent.com/a42663997bf6dd4542e14317261a4a9def0feac63bf7926b1f197baf1afb8700/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f6c696e75787365727665722f646f636b65722d626f6f6b737461636b2e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6f676f3d676974687562)](https://github.com/linuxserver/docker-bookstack/releases) [![GitHub Package Repository](https://camo.githubusercontent.com/1f594eaaf805a9428ee37c12cd49218b52ac74e83618e4b7b6c004860cdaf96a/68747470733a2f2f696d672e736869656c64732e696f2f7374617469632f76312e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d6c696e75787365727665722e696f266d6573736167653d4769744875622532305061636b616765266c6f676f3d676974687562)](https://github.com/linuxserver/docker-bookstack/packages) [![GitLab Container Registry](https://camo.githubusercontent.com/61016415992881b024fb77c00e202727e0e5c1d7ff26bb0b002d2359947bba01/68747470733a2f2f696d672e736869656c64732e696f2f7374617469632f76312e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d6c696e75787365727665722e696f266d6573736167653d4769744c61622532305265676973747279266c6f676f3d6769746c6162)](https://gitlab.com/linuxserver.io/docker-bookstack/container_registry) [![Quay.io](https://camo.githubusercontent.com/b170dc305ac9bf57bed4299dfb6a4b7b49dce97620f9daa7ad705801d1fa639c/68747470733a2f2f696d672e736869656c64732e696f2f7374617469632f76312e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d6c696e75787365727665722e696f266d6573736167653d517561792e696f)](https://quay.io/repository/linuxserver.io/bookstack) [![Docker Pulls](https://camo.githubusercontent.com/4d488a15b69b83f9bdcbea4c5a612001c1f693ae5315711142e59bed704adc6e/68747470733a2f2f696d672e736869656c64732e696f2f646f636b65722f70756c6c732f6c696e75787365727665722f626f6f6b737461636b2e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d70756c6c73266c6f676f3d646f636b6572)](https://hub.docker.com/r/linuxserver/bookstack) [![Docker Stars](https://camo.githubusercontent.com/3fada8707286807f4f050bd16aa1e957f3acb73cdcfc794b0d931b6c96244842/68747470733a2f2f696d672e736869656c64732e696f2f646f636b65722f73746172732f6c696e75787365727665722f626f6f6b737461636b2e7376673f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d7374617273266c6f676f3d646f636b6572)](https://hub.docker.com/r/linuxserver/bookstack) [![Jenkins Build](https://camo.githubusercontent.com/45d7fc603ce52df7dfe13fff46fe81af2cfe2141d492b0fee54825bc17f5ee0d/68747470733a2f2f696d672e736869656c64732e696f2f6a656e6b696e732f6275696c643f6c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266a6f6255726c3d687474707325334125324625324663692e6c696e75787365727665722e696f2532466a6f62253246446f636b65722d506970656c696e652d4275696c646572732532466a6f62253246646f636b65722d626f6f6b737461636b2532466a6f622532466d6173746572253246266c6f676f3d6a656e6b696e73)](https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-bookstack/job/master/)

[Bookstack](https://github.com/BookStackApp/BookStack) is a free and open source Wiki designed for creating beautiful documentation. Featuring a simple, but powerful WYSIWYG editor it allows for teams to create detailed and useful documentation with ease.

Powered by SQL and including a Markdown editor for those who prefer it, BookStack is geared towards making documentation more of a pleasure than a chore.

For more information on BookStack visit their website and check it out: [https://www.bookstackapp.com](https://www.bookstackapp.com/)

[![bookstack](https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/bookstack-logo.png)](https://github.com/BookStackApp/BookStack)

## Supported Architectures

<div class="markdown-heading" dir="auto" id="bkmrk--4" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#supported-architectures)</div>We utilise the docker manifest for multi-platform awareness. More information is available from docker [here](https://distribution.github.io/distribution/spec/manifest-v2-2/#manifest-list) and our announcement [here](https://blog.linuxserver.io/2019/02/21/the-lsio-pipeline-project/).

Simply pulling `lscr.io/linuxserver/bookstack:latest` should retrieve the correct image for your arch, but you can also pull specific arch images via tags.

The architectures supported by this image are:

<table id="bkmrk-architecture-availab"><thead><tr><th align="center">Architecture</th><th align="center">Available</th><th>Tag</th></tr></thead><tbody><tr><td align="center">x86-64</td><td align="center">✅</td><td>amd64-&lt;version tag&gt;</td></tr><tr><td align="center">arm64</td><td align="center">✅</td><td>arm64v8-&lt;version tag&gt;</td></tr><tr><td align="center">armhf</td><td align="center">❌</td><td> </td></tr></tbody></table>

## Application Setup

<div class="markdown-heading" dir="auto" id="bkmrk--6" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#application-setup)</div>The default username is <admin@admin.com> with the password of **password**, access the container at http://:6875.

This application is dependent on a MariaDB database, be it one you already have or a new one. If you do not already have one, we provide an image here [https://github.com/linuxserver/docker-mariadb](https://github.com/linuxserver/docker-mariadb).

If you intend to use this application behind a subfolder reverse proxy, such as our SWAG container or Traefik you will need to make sure that the `APP_URL` environment variable is set to your external domain, or it will not work.

Documentation for BookStack can be found at [https://www.bookstackapp.com/docs/](https://www.bookstackapp.com/docs/).

### BookStack File &amp; Directory Paths

<div class="markdown-heading" dir="auto" id="bkmrk--8" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#bookstack-file--directory-paths)</div>This container ensures certain BookStack application files &amp; folders, such as user file upload folders, are retained within the `/config` folder so that they are persistent &amp; accessible when the `/config` container path is bound as a volume. There may be cases, when following the BookStack documentation, that you'll need to know how these files and folders are used relative to a non-container BookStack installation.

Below is a mapping of container `/config` paths to those relative within a BookStack install directory:

- **/config container path** =&gt; **BookStack relative path**
- `/config/www/.env` =&gt; `.env`
- `/config/log/bookstack/laravel.log` =&gt; `storage/logs/laravel.log`
- `/config/backups/` =&gt; `storage/backups/`
- `/config/www/files/` =&gt; `storage/uploads/files/`
- `/config/www/images/` =&gt; `storage/uploads/images/`
- `/config/www/themes/` =&gt; `themes/`
- `/config/www/uploads/` =&gt; `public/uploads/`

### Changing APP\_URL

<div class="markdown-heading" dir="auto" id="bkmrk--10" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#changing-app_url)</div>If you change the APP\_URL after initial install, you should run the following line from your host terminal to update the database URL entries:

```
docker exec -it bookstack php /app/www/artisan bookstack:update-url ${OLD_URL} ${NEW_URL}
```

<div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" id="bkmrk--12" style="text-align: justify;"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>### Advanced Users (full control over the .env file)

<div class="markdown-heading" dir="auto" id="bkmrk--13" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#advanced-users-full-control-over-the-env-file)</div>If you wish to use the extra functionality of BookStack such as email, LDAP and so on you will need to set additional environment variables or make your own .env file with guidance from the BookStack documentation.

The container will copy an exemplary .env file to /config/www/.env on your host system for you to use.

## Read-Only Operation

<div class="markdown-heading" dir="auto" id="bkmrk--15" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#read-only-operation)</div>This image can be run with a read-only container filesystem. For details please [read the docs](https://docs.linuxserver.io/misc/read-only/).

### Caveats

<div class="markdown-heading" dir="auto" id="bkmrk--17" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#caveats)</div>- `/tmp` must be mounted to tmpfs

## Usage

<div class="markdown-heading" dir="auto" id="bkmrk--19" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#usage)</div>To help you get started creating a container from this image you can either use docker-compose or the docker cli.

<svg aria-hidden="true" class="octicon octicon-info mr-2" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8Zm8-6.5a6.5 6.5 0 1 0 0 13 6.5 6.5 0 0 0 0-13ZM6.5 7.75A.75.75 0 0 1 7.25 7h1a.75.75 0 0 1 .75.75v2.75h.25a.75.75 0 0 1 0 1.5h-2a.75.75 0 0 1 0-1.5h.25v-2h-.25a.75.75 0 0 1-.75-.75ZM8 6a1 1 0 1 1 0-2 1 1 0 0 1 0 2Z"></path></svg>Note

Unless a parameter is flaged as 'optional', it is *mandatory* and a value must be provided.

### docker-compose (recommended, [click here for more info](https://docs.linuxserver.io/general/docker-compose))

<div class="markdown-heading" dir="auto" id="bkmrk--21" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#docker-compose-recommended-click-here-for-more-info)</div>```
---
services:
  bookstack:
    image: lscr.io/linuxserver/bookstack:latest
    container_name: bookstack
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Etc/UTC
      - APP_URL=
      - APP_KEY=
      - DB_HOST=
      - DB_PORT=3306
      - DB_USERNAME=
      - DB_PASSWORD=
      - DB_DATABASE=
      - QUEUE_CONNECTION= #optional
    volumes:
      - /path/to/bookstack/config:/config
    ports:
      - 6875:80
    restart: unless-stopped
```

<div class="highlight highlight-source-yaml notranslate position-relative overflow-auto" dir="auto" id="bkmrk--23" style="text-align: justify;"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>### docker cli ([click here for more info](https://docs.docker.com/engine/reference/commandline/cli/))

<div class="markdown-heading" dir="auto" id="bkmrk--24" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#docker-cli-click-here-for-more-info)</div>```
docker run -d \
  --name=bookstack \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e APP_URL= \
  -e APP_KEY= \
  -e DB_HOST= \
  -e DB_PORT=3306 \
  -e DB_USERNAME= \
  -e DB_PASSWORD= \
  -e DB_DATABASE= \
  -e QUEUE_CONNECTION= `#optional` \
  -p 6875:80 \
  -v /path/to/bookstack/config:/config \
  --restart unless-stopped \
  lscr.io/linuxserver/bookstack:latest
```

<div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" id="bkmrk--26" style="text-align: justify;"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>## Parameters

<div class="markdown-heading" dir="auto" id="bkmrk--27" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#parameters)</div>Containers are configured using parameters passed at runtime (such as those above). These parameters are separated by a colon and indicate `<external>:<internal>` respectively. For example, `-p 8080:80` would expose port `80` from inside the container to be accessible from the host's IP on port `8080` outside the container.

<table id="bkmrk-parameter-function--" style="width: 100%;"><thead><tr><th align="center" style="width: 20.736%;">Parameter</th><th style="width: 79.2641%;">Function</th></tr></thead><tbody><tr><td align="center" style="width: 20.736%;">`-p 6875:80`</td><td style="width: 79.2641%;">http/s web interface.</td></tr><tr><td align="center" style="width: 20.736%;">`-e PUID=1000`</td><td style="width: 79.2641%;">for UserID - see below for explanation</td></tr><tr><td align="center" style="width: 20.736%;">`-e PGID=1000`</td><td style="width: 79.2641%;">for GroupID - see below for explanation</td></tr><tr><td align="center" style="width: 20.736%;">`-e TZ=Etc/UTC`</td><td style="width: 79.2641%;">specify a timezone to use, see this [list](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List).</td></tr><tr><td align="center" style="width: 20.736%;">`-e APP_URL=`</td><td style="width: 79.2641%;">The protocol, IP/URL, and port that your application will be accessed on (ie. `http://192.168.1.1:6875` or `https://bookstack.mydomain.com`</td></tr><tr><td align="center" style="width: 20.736%;">`-e APP_KEY=`</td><td style="width: 79.2641%;">Session encryption key. You will need to generate this with `docker run -it --rm --entrypoint /bin/bash lscr.io/linuxserver/bookstack:latest appkey`</td></tr><tr><td align="center" style="width: 20.736%;">`-e DB_HOST=`</td><td style="width: 79.2641%;">The database instance hostname</td></tr><tr><td align="center" style="width: 20.736%;">`-e DB_PORT=3306`</td><td style="width: 79.2641%;">Database port</td></tr><tr><td align="center" style="width: 20.736%;">`-e DB_USERNAME=`</td><td style="width: 79.2641%;">Database user</td></tr><tr><td align="center" style="width: 20.736%;">`-e DB_PASSWORD=`</td><td style="width: 79.2641%;">Database password (minimum 4 characters &amp; non-alphanumeric passwords must be properly escaped.)</td></tr><tr><td align="center" style="width: 20.736%;">`-e DB_DATABASE=`</td><td style="width: 79.2641%;">Database name</td></tr><tr><td align="center" style="width: 20.736%;">`-e QUEUE_CONNECTION=`</td><td style="width: 79.2641%;">Set to `database` to enable async actions like sending email or triggering webhooks. See [documentation](https://www.bookstackapp.com/docs/admin/email-webhooks/#async-action-handling).</td></tr><tr><td align="center" style="width: 20.736%;">`-v /config`</td><td style="width: 79.2641%;">Persistent config files</td></tr><tr><td align="center" style="width: 20.736%;">`--read-only=true`</td><td style="width: 79.2641%;">Run container with a read-only filesystem. Please [read the docs](https://docs.linuxserver.io/misc/read-only/).</td></tr></tbody></table>

## Environment variables from files (Docker secrets)

<div class="markdown-heading" dir="auto" id="bkmrk--29" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#environment-variables-from-files-docker-secrets)</div>You can set any environment variable from a file by using a special prepend `FILE__`.

As an example:

```
-e FILE__MYVAR=/run/secrets/mysecretvariable
```

<div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" id="bkmrk--31" style="text-align: justify;"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>Will set the environment variable `MYVAR` based on the contents of the `/run/secrets/mysecretvariable` file.

## Umask for running applications

<div class="markdown-heading" dir="auto" id="bkmrk--32" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#umask-for-running-applications)</div>For all of our images we provide the ability to override the default umask settings for services started within the containers using the optional `-e UMASK=022` setting. Keep in mind umask is not chmod it subtracts from permissions based on it's value it does not add. Please read up [here](https://en.wikipedia.org/wiki/Umask) before asking for support.

## User / Group Identifiers

<div class="markdown-heading" dir="auto" id="bkmrk--34" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#user--group-identifiers)</div>When using volumes (`-v` flags), permissions issues can arise between the host OS and the container, we avoid this issue by allowing you to specify the user `PUID` and group `PGID`.

Ensure any volume directories on the host are owned by the same user you specify and any permissions issues will vanish like magic.

In this instance `PUID=1000` and `PGID=1000`, to find yours use `id your_user` as below:

```
id your_user
```

<div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" id="bkmrk--36" style="text-align: justify;"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>Example output:

```
uid=1000(your_user) gid=1000(your_user) groups=1000(your_user)

```

<div class="snippet-clipboard-content notranslate position-relative overflow-auto" id="bkmrk--37" style="text-align: justify;"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>## Docker Mods

<div class="markdown-heading" dir="auto" id="bkmrk--38" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#docker-mods)</div>[![Docker Mods](https://camo.githubusercontent.com/12c0c24651952a186e5e5d4076bb26338781c7e90a1ac80072c5c238df2ff109/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f64796e616d69632f79616d6c3f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d626f6f6b737461636b2671756572793d2532342e6d6f6473253542253237626f6f6b737461636b2532372535442e6d6f645f636f756e742675726c3d68747470732533412532462532467261772e67697468756275736572636f6e74656e742e636f6d2532466c696e7578736572766572253246646f636b65722d6d6f64732532466d61737465722532466d6f642d6c6973742e796d6c)](https://mods.linuxserver.io/?mod=bookstack "view available mods for this container.") [![Docker Universal Mods](https://camo.githubusercontent.com/5fd7f2836ef672b3860ed7c359d13fa2ab96a45ade2df0ee36b4f28d52b30960/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f64796e616d69632f79616d6c3f636f6c6f723d393433393864266c6162656c436f6c6f723d353535353535266c6f676f436f6c6f723d666666666666267374796c653d666f722d7468652d6261646765266c6162656c3d756e6976657273616c2671756572793d2532342e6d6f6473253542253237756e6976657273616c2532372535442e6d6f645f636f756e742675726c3d68747470732533412532462532467261772e67697468756275736572636f6e74656e742e636f6d2532466c696e7578736572766572253246646f636b65722d6d6f64732532466d61737465722532466d6f642d6c6973742e796d6c)](https://mods.linuxserver.io/?mod=universal "view available universal mods.")

We publish various [Docker Mods](https://github.com/linuxserver/docker-mods) to enable additional functionality within the containers. The list of Mods available for this image (if any) as well as universal mods that can be applied to any one of our images can be accessed via the dynamic badges above.

## Support Info

<div class="markdown-heading" dir="auto" id="bkmrk--40" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#support-info)</div>- Shell access whilst the container is running:
    
    ```
    docker exec -it bookstack /bin/bash
    ```
    
    <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
- To monitor the logs of the container in realtime:
    
    ```
    docker logs -f bookstack
    ```
    
    <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
- Container version number:
    
    ```
    docker inspect -f '{{ index .Config.Labels "build_version" }}' bookstack
    ```
    
    <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
- Image version number:
    
    ```
    docker inspect -f '{{ index .Config.Labels "build_version" }}' lscr.io/linuxserver/bookstack:latest
    ```
    
    <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>

## Updating Info

<div class="markdown-heading" dir="auto" id="bkmrk--42" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#updating-info)</div>Most of our images are static, versioned, and require an image update and container recreation to update the app inside. With some exceptions (noted in the relevant readme.md), we do not recommend or support updating apps inside the container. Please consult the [Application Setup](https://github.com/linuxserver/docker-bookstack/tree/master#application-setup) section above to see if it is recommended for the image.

Below are the instructions for updating containers:

### Via Docker Compose

<div class="markdown-heading" dir="auto" id="bkmrk--44" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#via-docker-compose)</div>- Update images:
    
    
    - All images:
        
        ```
        docker-compose pull
        ```
        
        <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
    - Single image:
        
        ```
        docker-compose pull bookstack
        ```
        
        <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
- Update containers:
    
    
    - All containers:
        
        ```
        docker-compose up -d
        ```
        
        <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
    - Single container:
        
        ```
        docker-compose up -d bookstack
        ```
        
        <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
- You can also remove the old dangling images:
    
    ```
    docker image prune
    ```
    
    <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>

### Via Docker Run

<div class="markdown-heading" dir="auto" id="bkmrk--46" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#via-docker-run)</div>- Update the image:
    
    ```
    docker pull lscr.io/linuxserver/bookstack:latest
    ```
    
    <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
- Stop the running container:
    
    ```
    docker stop bookstack
    ```
    
    <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
- Delete the container:
    
    ```
    docker rm bookstack
    ```
    
    <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>
- Recreate a new container with the same docker run parameters as instructed above (if mapped correctly to a host folder, your `/config` folder and settings will be preserved)
- You can also remove the old dangling images:
    
    ```
    docker image prune
    ```
    
    <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>

### Image Update Notifications - Diun (Docker Image Update Notifier)

<div class="markdown-heading" dir="auto" id="bkmrk--48" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#image-update-notifications---diun-docker-image-update-notifier)</div><svg aria-hidden="true" class="octicon octicon-light-bulb mr-2" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M8 1.5c-2.363 0-4 1.69-4 3.75 0 .984.424 1.625.984 2.304l.214.253c.223.264.47.556.673.848.284.411.537.896.621 1.49a.75.75 0 0 1-1.484.211c-.04-.282-.163-.547-.37-.847a8.456 8.456 0 0 0-.542-.68c-.084-.1-.173-.205-.268-.32C3.201 7.75 2.5 6.766 2.5 5.25 2.5 2.31 4.863 0 8 0s5.5 2.31 5.5 5.25c0 1.516-.701 2.5-1.328 3.259-.095.115-.184.22-.268.319-.207.245-.383.453-.541.681-.208.3-.33.565-.37.847a.751.751 0 0 1-1.485-.212c.084-.593.337-1.078.621-1.489.203-.292.45-.584.673-.848.075-.088.147-.173.213-.253.561-.679.985-1.32.985-2.304 0-2.06-1.637-3.75-4-3.75ZM5.75 12h4.5a.75.75 0 0 1 0 1.5h-4.5a.75.75 0 0 1 0-1.5ZM6 15.25a.75.75 0 0 1 .75-.75h2.5a.75.75 0 0 1 0 1.5h-2.5a.75.75 0 0 1-.75-.75Z"></path></svg>Tip

We recommend [Diun](https://crazymax.dev/diun/) for update notifications. Other tools that automatically update containers unattended are not recommended or supported.

## Building locally

<div class="markdown-heading" dir="auto" id="bkmrk--50" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#building-locally)</div>If you want to make local modifications to these images for development purposes or just to customize the logic:

```
git clone https://github.com/linuxserver/docker-bookstack.git
cd docker-bookstack
docker build \
  --no-cache \
  --pull \
  -t lscr.io/linuxserver/bookstack:latest .
```

<div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" id="bkmrk--52" style="text-align: justify;"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>The ARM variants can be built on x86\_64 hardware and vice versa using `lscr.io/linuxserver/qemu-static`

```
docker run --rm --privileged lscr.io/linuxserver/qemu-static --reset
```

<div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" id="bkmrk--53" style="text-align: justify;"><div class="zeroclipboard-container"><svg aria-hidden="true" class="octicon octicon-copy js-clipboard-copy-icon" data-view-component="true" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z"></path><path d="M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z"></path></svg></div></div>Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64`.

## Versions

<div class="markdown-heading" dir="auto" id="bkmrk--54" style="text-align: justify;">[<svg aria-hidden="true" class="octicon octicon-link" height="16" version="1.1" viewbox="0 0 16 16" width="16"><path d="m7.775 3.275 1.25-1.25a3.5 3.5 0 1 1 4.95 4.95l-2.5 2.5a3.5 3.5 0 0 1-4.95 0 .751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018 1.998 1.998 0 0 0 2.83 0l2.5-2.5a2.002 2.002 0 0 0-2.83-2.83l-1.25 1.25a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042Zm-4.69 9.64a1.998 1.998 0 0 0 2.83 0l1.25-1.25a.751.751 0 0 1 1.042.018.751.751 0 0 1 .018 1.042l-1.25 1.25a3.5 3.5 0 1 1-4.95-4.95l2.5-2.5a3.5 3.5 0 0 1 4.95 0 .751.751 0 0 1-.018 1.042.751.751 0 0 1-1.042.018 1.998 1.998 0 0 0-2.83 0l-2.5 2.5a1.998 1.998 0 0 0 0 2.83Z"></path></svg>](https://github.com/linuxserver/docker-bookstack/tree/master#versions)</div>- **04.01.25:** - Add php-opcache.
- **17.12.24:** - Rebase to Alpine 3.21.
- **11.10.24:** - Default to environment config over .env file config.
- **06.09.24:** - Add php-exif for reading image EXIF data.
- **27.05.24:** - Rebase to Alpine 3.20. Existing users should update their nginx confs to avoid http2 deprecation warnings.
- **25.01.24:** - Existing users should update: site-confs/default.conf - Cleanup default site conf.
- **23.12.23:** - Rebase to Alpine 3.19 with php 8.3.
- **31.10.23:** - Further sanitize sed replace.
- **07.06.23:** - Add mariadb-client for bookstack-system-cli support.
- **25.05.23:** - Rebase to Alpine 3.18, deprecate armhf.
- **13.04.23:** - Move ssl.conf include to default.conf.
- **01.03.23:** - Add php iconv.
- **19.01.23:** - Rebase to alpine 3.17 with php8.1.
- **16.01.23:** - Wrap `.env` values in quotes.
- **05.01.23:** - Fix db password setting (sed escape `&`).
- **21.12.22:** - Update db info in .env file when env vars are updated.
- **10.10.22:** - Remove password escape logic which caused problems for a small subset of users.
- **20.08.22:** - Rebasing to alpine 3.15 with php8. Restructure nginx configs ([see changes announcement](https://info.linuxserver.io/issues/2022-08-20-nginx-base)).
- **14.03.22:** - Add symlinks for theme support.
- **11.07.21:** - Rebase to Alpine 3.14.
- **12.01.21:** - Remove unused requirement, as of release 0.31.0.
- **17.12.20:** - Make APP\_URL var required (upstream changes).
- **17.09.20:** - Rebase to alpine 3.12. Fix APP\_URL setting. Bump php post max and upload max filesizes to 100MB by default.
- **19.12.19:** - Rebasing to alpine 3.11.
- **26.07.19:** - Use old version of tidyhtml pending upstream fixes.
- **28.06.19:** - Rebasing to alpine 3.10.
- **14.06.19:** - Add wkhtmltopdf to image for PDF rendering.
- **20.04.19:** - Rebase to Alpine 3.9, add MySQL init logic.
- **22.03.19:** - Switching to new Base images, shift to arm32v7 tag.
- **20.01.19:** - Added php7-curl
- **04.11.18:** - Added php7-ldap
- **15.10.18:** - Changed functionality for advanced users
- **08.10.18:** - Advanced mode, symlink changes, sed fixing, docs updated, added some composer files
- **23.09.28:** - Updates pre-release
- **02.07.18:** - Initial Release.