PERF: Speed up building slim image by setting --jobs to number of cores (#770)
authorAlan Guo Xiang Tan <gxtan1990@gmail.com>
Tue, 6 Feb 2024 08:38:04 +0000 (16:38 +0800)
committerGitHub <noreply@github.com>
Tue, 6 Feb 2024 08:38:04 +0000 (16:38 +0800)
commit7cc301e9a96323e51017cd810df7cf917c65f77e
tree0c458c694b282f3b3ee995aee3b54eebe5e8e56b
parenta03cdcb2578d79d37440606add42676bd55c3c33
PERF: Speed up building slim image by setting --jobs to number of cores (#770)

On a M3 Max macbook pro with 14 cores,

Before:

```
=> [25/44] RUN /tmp/install-imagemagick                                 150.6s
=> [27/44] RUN /tmp/install-jemalloc                                     54.9s
=> [31/44] RUN /tmp/install-redis                                        42.9s
```

After:

```
=> [25/44] RUN /tmp/install-imagemagick                                  44.4s
=> [27/44] RUN /tmp/install-jemalloc                                     13.7s
=> [31/44] RUN /tmp/install-redis                                        11.7s
```
image/base/install-imagemagick
image/base/install-jemalloc
image/base/install-redis