Time for an update to our recommended setup for a no-hassle dev environment and editor, complete with an integrated step debugger.
[xdebug]
xdebug.mode = debug
xdebug.client_port = 9000
zend_extension = C:\laragon\bin\php\php-7.4.13-Win32-VC15-x64\ext\php_xdebug-3.0.1-7.4-vc15-x86_64.dll
xdebug.client_port
to the value in your launch.json
file. At the moment (2020-12-13) the file in your launch.json
file after a fresh install of everything is 9000 while XDebug 3.x is listening on 9003.launch.json
file to 9003 or include the xdebug.client_port = 9000
entry in your php.ini as @mithril posted above. With XDebug 3 you don't need the xdebug.remote_enable
or xdebug.remote_autostart
lines specified in the video. Just fixing that - we had a bit of a docs refresh at the weekend and somehow this got missed. It should be back in a few minutes.
When you say 'the XF editor' - are you referring to the WYSIWYG editor built into XF, or the CodeMirror code editor in XF, or the editor Mike, Chris and I use to actually edit the XF code? Sorry if I'm being slow...@Kier, recommendation on what VS keymappings to use to be the same as the XF editor? I was trying to find if it was mentioned in the forums what mappings the XF the editor is using (eg:CTRL+D
to delete a line) but didn't spot it. I'm thinking the Eclipse mapping? 🤔
Download it in a different browser, Edge is being stupid.
I was thinking along the lines of the editor used in the ACP when, for example, editing templates andWhen you say 'the XF editor' - are you referring to the WYSIWYG editor built into XF, or the CodeMirror code editor in XF, or the editor Mike, Chris and I use to actually edit the XF code? Sorry if I'm being slow...
CTRL+D
can be used to delete a line versus the defaults of VS Code where it's SHIFT+CTRL+K
. version: '2'
# https://github.com/xfrocks/docker-xenforo
services:
php:
image: xfrocks/xenforo:php-apache
ports:
- "80:80"
links:
- mysql
volumes:
- ./:/var/www/html/
mysql:
image: mysql
environment:
MYSQL_RANDOM_ROOT_PASSWORD: 'yes'
MYSQL_DATABASE: 'database'
MYSQL_USER: 'user'
MYSQL_PASSWORD: 'password'
expose:
- "3306"
volumes:
- ./internal_data/mysql:/var/lib/mysql
We run it within containers for production (https://7Cav.us)Is anyone using docker in production? I'm trying to write an addon to give access to subforums based on access levels in our existing database. We want a hybrid public-private membership forum. I'm trying to find the ideal way to run XenForo in docker for a production environment - not just dev - if anyone knows. I see there is no official docker image for XenForo![]()
Thanks! An (officially blessed) Dockerfile to build an image for XF using the licensed download would be just as good. I'll try the repo you linked to in the beginning of this thread. In terms of what I'm trying to do: https://xenforo.com/community/threads/requirements-for-access-level-subforums-db-integration.206538/We run it within containers for production (https://7Cav.us)
What did you need help with? There’s no official container because that would easily leak the PHP source code for XF
Thanks! An (officially blessed) Dockerfile to build an image for XF using the licensed download would be just as good. I'll try the repo you linked to in the beginning of this thread. In terms of what I'm trying to do: https://xenforo.com/community/threads/requirements-for-access-level-subforums-db-integration.206538/
Is the docker-compose.yml in your repo the same one you use to run XF in production?
Great, that would be good to have - and perhaps we can get some other XF users to use the same production compose file to help keep an eye out for issues. I'll be using traefik in from of it rather than nginx.Not exactly, but close
I can go grab the compose we use for prod later today after work. However, we also use a nginx proxy in front of everything - so it may seem a little off
Though, it’s still the combo of its own nginx ‘sidecar’ and the fpm image for PHP
Sounds goodGreat, that would be good to have - and perhaps we can get some other XF users to use the same production compose file to help keep an eye out for issues. I'll be using traefik in from of it rather than nginx.
We use essential cookies to make this site work, and optional cookies to enhance your experience.