Wordpress site is so slow!

Hello everyone,

I work with Devilbox and Docker since a few years. I’m not into configurations and console, I’m a front dev.

I work only with Wordpress, and it’s so slow ! I have to wait generally 30 sec for a page to load, even if it’s an empty website without modules.

I’ve read that you need to change docker-compose.override.yml so that’s what I put inside :

# vim: set ft=yaml:
---
version: '2.3'

services:
  php:
    environment:
      PHP_MEMORY_LIMIT: 1G
  mysql:
    environment:
      MYSQL_INIT_MEMORY: 512M
      MYSQL_MAX_MEMORY: 1G
      MYSQL_QUERY_CACHE_SIZE: 128M

My computer is a gaming computer so it should not be a problem to run this tools (Ryzen 7 3700X 8 core, 32go RAM…).

If I want to change Docker’s configuration, in Resources, it’s says “You are using the WSL 2 backend, so resource limits are managed by Windows.” I tried to create a .wslconfig with that inside :

[wsl2]
memory=16GB  
processors=8 

But it changed nothing.

Can someone help me please ? I can’t continue to work like this, it takes me ages to do everything…

Thanks !

I use devilbox primarily for developing for wordpress and it runs well/quickly for me. Though I am on a Mac.

When you start up the devilbox, it helps to not start all the available modules. Only run what you need for Wordpress. I start it like this so that I only get the dns server, php, apache, and mysql.

docker-compose up -d bind httpd php mysql

Hi, thank you for the reply.

I’ve got this :

docker-compose up -d httpd php mysql bind mailhog

So the minimum too, like you (except for mailhog that I added a few weeks ago, but the lagging have been there for years now…).

Can someone help me ? I’m gonna hang myself if this keep being so slow -_-

Use Hyper V instead of WSL 2. and see the performance.

1 Like

I’ve just changed to Laragon, and my pages loads in 1-3 seconds, so maybe I’ll stay with that. But if not, I’ll look at what you proposed.