Categories
Uncategorized

Speeding up Magento Docker dev env

I have several Magento 1.9 development environments running on Docker Compose and Docker Desktop for Mac, both of which have always been slow. Every page reload took 6-10 seconds which really hit productivity.

A friend pointed me to Docker’s settings for bind-mount consistency. By default, when a file is written inside the container, the system waits for that change to be persisted to the host before continuing. The opposite happens for changes written to the host. It’s very quick, but if there are hundreds of changes, it noticeably affects performance.

If you’re willing/able to settle for eventual consistency, things move more quickly. I switched the MySQL data volume to “delegated”, which means the version inside the container is authoritative. That’s where all the MySQL changes happen.

I also switched the Magento filesystem, this time to “cached”. With “cached”, the files on the host system (macOS) are authoritative. It seems unlikely that I’ll manage a manual browser refresh before the macOS change is persisted into the container!

There’s more info about performance of shared volumes in the Docker docs.

Categories
Uncategorized

How to do professional services, according to Michelangelo

I finished David Lough’s No More Champagne: Churchill and his Money. I’m not sure that anyone could call the former prime minister poor, but he did have a fairly loose attitude to cashflow management. Interesting book. I don’t envy the amount of research that went into writing it.

Found a good story while flicking through a mini table-top book about Michelangelo’s David, which suggests he may have been as good at professional services as he was at sculpture.

The first person to see the statue was the gonfalonier Pier Soderini and Vasari records the episode in a famous anecdote (1568). While impressed by the sight, the Florentine notable said to Buonarroti “that it seemed to him that the nose of the figure was too thick.” Michelangelo climbed up on the scaffolding, grabbed his chisel and a little marble dust from the planks, struck lightly with the tool and let the dust fall, leading Soderini, who could not actually see, to believe that he had, indeed modified the nose. Unknowing, but satisfied the gonfalonier said “You have given it life.”

Elena Capretti, Michelangelo (Giunti; 2006)
The nose in question.
Categories
Uncategorized

Hello world!

Welcome to WordPress. This is your first post.

What this post originally said.

It certainly is my first post. The 2020 WordPress theme is quite appealing on all the screens; good news, because you’re stuck with it for a while!