Docker
On this page, you can find instructions on how to instal MIND using Docker and how to update a Docker installation.
Installation¶
Time settings¶
Make sure to set all time related settings (time, date, timezone, etc.) correct on your computer, as MIND depends on it to work correctly.
Instal Docker¶
The first step is to instal Docker, if you don't have it installed already. The official Docker documentation hub offers great instructions on how to instal docker CLI and Docker Desktop. Take notice of if you installed the 'Docker CLI' (the Docker documentation also calls this 'Docker CE') or if you installed 'Docker Desktop', for future instructions.
Create Docker volume or folder¶
MIND needs a permanent place to put the database file, which contains all the user data and configs. This can be a Docker volume, or a folder on the host machine.
Linux standards would suggest putting the folder in /opt/application_name
, as the /opt
directory is where program options should be stored. This is not mandatory however; you are allowed to create a folder anywhere you like. If we apply the standard to MIND, the folder would be /opt/MIND/db
.
Create the desired folder using the UI (if your distro offers this) or with the following shell command (replace /path/to/directory
with desired path):
Permissions and ownership
The permissions on this folder need to allow the container to read, write, and execute inside it. It also needs to have proper ownership. More documentation on this subject coming.
MacOS standards would suggest putting the folder in /Applications/application_name
. This is not mandatory however; you are allowed to create a folder anywhere you like. If we apply the standard to MIND, the folder would be /Applications/MIND/db
.
Create the desired folder using the UI or with the following shell command (replace /path/to/directory
with desired path):
Permissions and ownership
The permissions on this folder need to allow the container to read, write, and execute inside it. It also needs to have proper ownership. More documentation on this subject coming.
There is no defined standard for Windows on where to put such a folder. We suggest a path like C:\apps\application_name
, so that it can be managed easily. This is not mandatory however; you are allowed to create a folder anywhere you like. If we apply this suggestion to MIND, the folder would be C:\apps\MIND\db
.
Create the desired folder either using the Windows Explorer, or using the following Powershell command:
Permissions and ownership
The permissions on this folder need to allow the container to read, write, and execute inside it. It also needs to have proper ownership. More documentation on this subject coming.
Launch container¶
Now we can launch the container.
The command to get the Docker container running can be found below. But before you copy, paste and run it, read the notes below!
A few notes about this command:
-
If you're using a folder on the host machine instead of a docker volume to store the database file (reference), replace
mind-db
with the path to the host folder.
E.g."/opt/MIND/db:/app/db"
.
E.g."C:\apps\MIND\db:/app/db"
. -
Replace the timezone value (
TZ=
) with the TZ database name of your timezone (value ofTZ identifier
on webpage). -
Information on how to change the port can be found on the Setup After Installation page.
The contents of the docker-compose.yml
file are below. The source file can also be found on GitHub. But before you copy, paste and run it, read the notes below!
version: "3.3"
services:
mind:
container_name: mind
image: mrcas/mind:latest
volumes:
- "mind-db:/app/db"
environment:
- TZ=Europe/Amsterdam
ports:
- 8080:8080
volumes:
mind-db:
Then run the following command to start the container. Run this command from within the directory where the docker-compose.yml
file is located.
A few notes about the docker-compose.yml
file:
-
If you're using a folder on the host machine instead of a docker volume to store the database file (reference), replace
mind-db
with the path to the host folder.
E.g."/opt/MIND/db:/app/db"
.
E.g."C:\apps\MIND\db:/app/db"
. -
Replace the timezone value (
TZ=
) with the TZ database name of your timezone (value ofTZ identifier
on webpage). -
Information on how to change the port can be found on the Setup After Installation page.
- Click the search bar at the top and search for
mrcas/mind
. - Click
Run
on the entry sayingmrcas/mind
. - Open
Images
, and on the right, underActions
click the play/run button formrcas/mind
. - Expand the 'Optional settings'.
- For the
Container name
, set the value tomind
. - For the
Host port
, set the value to8080
. Information on how to change the port can be found on the Setup After Installation page. - For the
Host path
, set the value tomind-db
if you are using a Docker volume for the database. Otherwise, set it to the folder where you want to store the database, that you created earlier. Set the accompanyingContainer path
to/app/db
. - For the
Variable
, set the value toTZ
. Set the accompanyingValue
to the TZ database name of your timezone (value ofTZ identifier
on webpage). E.g.Europe/Amsterdam
.
Update instal¶
Below you can find instructions on how to update an instal.
If needed, run these commands with sudo
. It is assumed that the name of the container is mind
(which is set using the --name
option in the command).
docker container stop mind
docker container rm mind
docker image rm mrcas/mind:latest
- Run the command you previously used to start the container.
If needed, run these commands with sudo
. You need to be in the same directory as the docker-compose.yml
file when running these commands.
docker-compose down
docker-compose pull
docker-compose up -d
docker image prune -f
- Open
Containers
and locate themind
container in the list. - Click the stop button on the right, then the delete button.
- Open
Images
and locate themrcas/mind
image in the list. - Click the delete button on the right.
- Repeat the steps of launching the container.