mybb / docker Goto Github PK
View Code? Open in Web Editor NEWThe official Dockerfile for the MyBB forum software.
Home Page: https://mybb.com
License: BSD 3-Clause "New" or "Revised" License
The official Dockerfile for the MyBB forum software.
Home Page: https://mybb.com
License: BSD 3-Clause "New" or "Revised" License
Hello,
Could you publish v1.8.34 image please?
I installed a docker container just a few seconds ago with following exact command:
docker container run -d --name mybb-test -p 8099:80/tcp mybb/mybb:latest
I wanted to open the container called "mybb-test" on the port 8099 of my host-system (80 is already in use).
I understand that there is no database or anything yet, but normally after installing mybb you get this nice install wizard and when I try to open my ip plus the port in the browser I only get a denied request message.
What am I doing wrong?
Is it possible to support an apache image? Is mybb apache compatible? this way, no nginx is needed.
Hi,
Could you publish v1.8.26 image?
Regards
Ulvhedin
Ran the example, also ran a slightly more filled-in config for a production deployment, fpm seems to be misconfigured (I'm not a PHP user so I'm only guessing).
Once the container is up, hitting the fpm endpoint just results in curl: (56) Recv failure: Connection reset by peer
, did this from inside the container to rule out any possible Docker network issues.
Here's a configuration to reproduce, just run this and curl localhost:9000
or exec
into the container and do the same:
version: "3.5"
networks:
default:
external:
name: gateway
database:
driver: bridge
internal: true
services:
mybb:
image: mybb/mybb:latest
volumes:
- ${DATA_DIR}/burgershot/mybb:/var/www/html
networks:
- default
- database
labels:
- traefik.docker.network=gateway
- traefik.frontend.rule=Host:example.com
- traefik.frontend.headers.SSLRedirect=false
- traefik.port=9000
postgresql:
image: postgres:10.4
environment:
POSTGRES_DB: mybb
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_USER: mybb
networks:
- database
volumes:
- ${DATA_DIR}/mybb/postgres/data:/var/lib/postgresql/data
Heyo!
So - I'm trying to keep my project light by letting the docker image handle the mybb install. however, this doesn't work because the extract overwrites all files within the destination. This means my language files get overwritten by the clean image files!
Would it be possible to add a flag to skip already present files on this line?
https://github.com/mybb/docker/blob/master/docker-entrypoint.sh#L10
By adding this flag:
https://stackoverflow.com/a/51171675
My docker setup would ideally look like the following:
version: '3.7'
services:
mybb:
build:
context: ./site
ports:
- 9000:9000
depends_on:
- mysql
volumes:
- ./site/inc/plugins:/var/www/html/inc/plugins
- ./site/inc/config.php:/var/www/html/inc/config.php
- ./site/inc/languages:/var/www/html/inc/languages
- site:/var/www/html
nginx:
build:
context: ./nginx
ports:
- 80:80
restart: on-failure
depends_on:
- mybb
volumes:
- site:/var/www/html:ro
mysql:
build:
context: ./mysql
command: --default-authentication-plugin=mysql_native_password
ports:
- 3306:3306
restart: always
volumes:
- ./mysql/data:/var/lib/mysql
volumes:
site:
And when mybb installs, it ideally would not overwrite my desired config.php or language file updates! thanks!
Could you please add information about how to access myBB once it has been launched with the Docker Compose file to the documentation? Which port/URL do you have to access to set it up?
Edit: I first tried accessing it on port 80 since the Docker Compose file suggests that that is where nginx is hosting it, but that only shows me the default "Welcome to nginx!" HTML page instead of the myBB setup page. Adding "/install" to the end URL didn't work either.
Hi, I found the php mail is not working in docker based version on my server, I've followed the instructions on https://docs.mybb.com/1.8/faq/mail/
but the received an error message. please investigate, thanks.
I've been trying to setup this docker image locally but I'm getting connection issues with Postgres.
When browsing to the nginx server, I get the install page. I try to start up the installation with the Postgres credentials setup in my docker compose file, however it doesn't connect.
The strange thing is, I'm able to connect using a postgres client, but not through then nginx mybb.
This is what I've got in my docker-compose.yaml
:
version: '3.6'
services:
mybb:
image: mybb/mybb:latest
volumes:
- ${PWD}/mybb:/var/www/html:rw
- ${PWD}/plugins:/var/www/html/inc/plugins:rw
depends_on:
- postgresql
links:
- postgresql
nginx:
image: nginx:mainline
ports:
- published: 8080
target: 80
volumes:
- ${PWD}/mybb:/var/www/html:ro
- ${PWD}/nginx:/etc/nginx/conf.d:ro
restart: always
postgresql:
environment:
POSTGRES_DB: mybb
POSTGRES_PASSWORD: changeme
POSTGRES_USER: mybb
image: postgres:10.4
ports:
- published: 5432
target: 5432
restart: always
volumes:
- ${PWD}/postgres/data:/var/lib/postgresql/data:rw
Then I've also got the nginx/default.conf file as described in the readme, unchanged.
Is the mybb container supposed to automatically install the tables, or are we supposed to do this manually? Any idea why it's not connecting?
Hi
When I try to build image from Dockerfile
with command:
docker build -t test-image-t1 .
Initially build works ok
but ultimately it fails with an error:
> [6/7] RUN set -ex; curl -o mybb.tar.gz -fSL "https://github.com/mybb/mybb/archive/refs/tags/mybb_.tar.gz"; echo " *mybb.tar.gz" | sha512sum -c -; tar -xzf mybb.tar.gz -C /usr/src/; rm mybb.tar.gz; chown -R www-data:www-data /usr/src/mybb-mybb_:
#9 0.188 + curl -o mybb.tar.gz -fSL https://github.com/mybb/mybb/archive/refs/tags/mybb_.tar.gz
#9 0.191 % Total % Received % Xferd Average Speed Time Time Time Current
#9 0.191 Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
0 14 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
#9 1.136 curl: (22) The requested URL returned error: 404
Do you know where I can find this file?
https://github.com/mybb/mybb/archive/refs/tags/mybb_.tar.gz
I'm using MacOS 13.0.1 with CPU ARM64 - that's why I want to build own image. The one from docker repo seems to be for AMD64.
Thank you & cheers
GT
edit:
Seems that standard image - works fine on M1 CPU. And in essence - the whole MyBB works well on docker.
Earlier I mistook 'docker compose' config.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.