Dev Container memory usage really high?

The official image aims to simplify development by bundling everything needed to run Discourse seamlessly, at the cost of higher memory requirements, and your custom setup seems to have a fine-grained control over versions and installed libraries.