<commit_before># Dokuwiki dokku deployment

To deploy a dokuwiki on dokku, persistant storage is needed. How you
choose to add this volume is up to you, but the volume should mount in
to `/docker-volume` and contain the dirs: `data`, `conf`, and `plugins`.
These dirs will then be symlinked like:

 - `data -> /app/data`
 - `conf -> /app/conf`
 - `plugins -> /app/lib/plugins`

Once this is done, the site will chown the files to be owned by the user
currently running the website, and then start the apache worker.

### Example volume configuration
Using the plugin: https://github.com/ohardy/dokku-volume

 - Add a volume to the instance with

```bash
dokku volume add dokuwiki /docker-volume
```

 - Find path to the volume

```bash
dokku volume list dokuwiki
```

It gives you something like:
`/home/dokku/.o_volume/data/1a298698-b480-4242-81e9-db98161932b3:/docker-volume`
, and you need the part before the ":".

 - Add directories

```bash
mkdir /home/dokku/.o_volume/data/1a298698-b480-4242-81e9-db98161932b3/{data,conf,plugins}
```

## Notes first use and upgrading

If you are running this for the first time, or updating to a newer
version of dokuwiki, please run the `update-dokuwiki` script as:

```bash
./update-dokuwiki
```

This will pull the latest stable version, remove the dirs you are
going to symlink in and cleanup.<commit_msg>Fixes: #2 Fixed error in install documentation<commit_after># Dokuwiki dokku deployment

To deploy a dokuwiki on dokku, persistant storage is needed. How you
choose to add this volume is up to you, but the volume should mount in
to `/docker-volume` and contain the dirs: `data`, `conf`, and `plugins`.
These dirs will then be symlinked like:

 - `data -> /app/data`
 - `conf -> /app/conf`
 - `plugins -> /app/lib/plugins`

Once this is done, the site will chown the files to be owned by the user
currently running the website, and then start the apache worker.

### Example volume configuration
Using the plugin: https://github.com/ohardy/dokku-volume

 - Add a volume to the instance with

```bash
dokku volume add dokuwiki /docker-volume
```

 - Find path to the volume

```bash
dokku volume list dokuwiki
```

It gives you something like:
`/home/dokku/.o_volume/data/1a298698-b480-4242-81e9-db98161932b3:/docker-volume`
, and you need the part before the ":".

 - Add directories

```bash
cd /tmp
wget -O latest.tgz http://download.dokuwiki.org/src/dokuwiki/dokuwiki-stable.tgz
tar -zxvf latest.tgz
cp -r dokuwiki*/data /home/dokku/.o_volume/data/1a298698-b480-4242-81e9-db98161932b3/
cp -r dokuwiki*/conf /home/dokku/.o_volume/data/1a298698-b480-4242-81e9-db98161932b3/
cp -r dokuwiki*/lib/plugins /home/dokku/.o_volume/data/1a298698-b480-4242-81e9-db98161932b3/
rm -r dokuwiki* latest.tgz
```

**NOTE:** If you are migrating an existing dokuwiki, copy in the `data`,
`conf` and `lib/plugins` directories into the created volume (as above).

## Notes first use and upgrading

If you are running this for the first time, or updating to a newer
version of dokuwiki, please run the `update-dokuwiki` script as:

```bash
./update-dokuwiki
```

This will pull the latest stable version, remove the dirs you are
going to symlink in and cleanup.
{'fraction_non_alphanumeric': 0.1055764411027569, 'fraction_numerical': 0.04918546365914787, 'mean_word_length': 3.973520249221184, 'pattern_counts': {'":': 2, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2906965', 'n_tokens_mistral': 1197, 'n_tokens_neox': 1052, 'n_words': 402}