Project

General

Profile

Running with Docker » History » Version 13

Luke Murphey, 01/01/2020 05:49 AM

1 1 Luke Murphey
h1. Running with Docker
2 1 Luke Murphey
3 2 Luke Murphey
h2. Prerequisites
4 1 Luke Murphey
5 2 Luke Murphey
You will need to have Docker installed. See https://docs.docker.com/install/.
6 2 Luke Murphey
7 2 Luke Murphey
You will also need a copy of the works database (library.sqlite).
8 2 Luke Murphey
9 2 Luke Murphey
h2. Getting the TextCritical Docker image running
10 2 Luke Murphey
11 12 Luke Murphey
h3. Step 1: Get the textcritical image from Docker Hub
12 1 Luke Murphey
13 12 Luke Murphey
<pre>
14 12 Luke Murphey
docker pull lukemurphey/textcritical
15 12 Luke Murphey
</pre>
16 1 Luke Murphey
17 12 Luke Murphey
h3. Step 2: Create the necessary directories on the host file-system
18 1 Luke Murphey
19 12 Luke Murphey
You will need to create a series of directories on your host file-system to store content. To do so create a directory such as "textcritical" and create a directory within it named "db".
20 1 Luke Murphey
21 12 Luke Murphey
h3. Step 3: Place your database files in "db"
22 2 Luke Murphey
23 12 Luke Murphey
Put library.sqlite under the "db" directory. You can use "the library of works attached":https://lukemurphey.net/attachments/download/461/library.sqlite to this wiki entry to get started quickly (although it only includes one work).
24 2 Luke Murphey
25 12 Luke Murphey
* db/library.sqlite
26 12 Luke Murphey
* db/textcritical.sqlite
27 2 Luke Murphey
28 12 Luke Murphey
h3. Step 4: Run the container
29 2 Luke Murphey
30 2 Luke Murphey
<pre>
31 13 Luke Murphey
docker run --restart always -d -p 8080:8080/tcp -v /opt/textcritical/db:/db lukemurphey/textcritical
32 2 Luke Murphey
</pre>
33 2 Luke Murphey
34 9 Luke Murphey
You should now be able to access TextCritical on port 8080 on your localhost (e.g. http://localhost:8080).
35 8 Luke Murphey
36 9 Luke Murphey
The instance is setup with a default login name of "admin" and a password of "changeme". You can log into the administration system at the URL "admin" (e.g. http://localhost:8080/admin/)