Im trying to get an installation of MyBB working using docker.
The issue is, I have no experience with docker so its quite a learning curve for me at the moment. I have decided to document my process here, as much for me for future reference, but also so I can hopefully ask for some advice (questions at bottom of post).
I have read through the Synology Help Pages for docker (Here), but there is some information missing regarding certain procedures.
Step 1 - Acquiring a MyBB Docker File
I searched for MyBB using Synology's docker search.
The docker file page shows the following (Docker Page)
Step 2 - Creating Volumes
The synology help states in the example given about mapping volumes to shared folders, but makes no mention of the correct procedure for creating these shared folders.
I was unsure if I can simply create these folders under admin account, or if they need to be created with root?
I found an article which would suggest that these folders should be created with root access using SSH. (See Here)
Using the information from the article above I logged into my Synology with SSH (on macOS), to gain root access.
Firstly, enabled SSH Service in Control Panel
Then followed this Synology Article to login with SSH / root access.
Then proceeded to create folders and change ownership as directed in article
Step 3 - Configuring the Container
Step 4 - Accessing MyBB through web browser
Using the address 192.168.1.100:9001 presents me with this page
Reading the MyBB docs specify what permissions are required for folders, specifying uploads needs a chmod of 777 (See Here)
Changing the permissions of the upload folder.
File Station shows all permissions set
Trying again, shows the uploads folder is now writable.
Q1. Creating the folders / Volumes :
I specified the method I used to create the folders in Step 2 - is this correct?
Q2. The docker file specifies the following :
Code: Select all
# Folders to mount in rw :
# - /logs
# - /app/inc/config.php
# - /app/inc/settings.php
# - /app/uploads
The /app/inc/config.php and /app/inc/settings.php are files as far as I am aware. How am I mean to account for this? Do I just need to create a /app/inc folder with appropriate permissions and in turn the files (presumably when created by MyBB) will inherit the permissions of their parent folder (/app/inc) ?
Q3. Uploads/Avatars not Writable
The Uploads/Avatars folder is still not writable. I realise I could probably rectify that with the following code
Code: Select all
mkdir -p volume1/mybb/app/uploads/avatars
chmod 777 volume1/mybb/app/uploads/avatars
However, the docker file makes no mention of needing to do this, so makes me doubt myself and wonder if I am missing something? It also makes me nervous that there may be other folders that need to be created that I am not aware of.
Q4. How do I know what folders/files are in the docker file / where are the files located on my Synology NAS?
The reason I ask this is for the following reasons :
1. Say I wanted to expose the 'themes' or 'plugins' folder so those files are accessible via docker/mybb/themes (for example), I would need to know the location of the 'themes' folder within the docker image. Can I do this, or does support for specific folders to be exposed need to be part of the docker container?
2. Some plugins require you to add / modify existing files of the MyBB installation - how do I get access to the appropriate folder within the docker container in order to add / modify existing files? (ftp to 192.168.1.100:9000 ?)
Q5. General Understanding
Do I appear to of grasped the basic concepts, or am I missing some fundamental principles that are potentially going to get me into some bother further down the line?
Thanks in advance for any help!