Skip to content

Conversation

chrisjsimpson
Copy link

@chrisjsimpson chrisjsimpson commented Sep 10, 2022

Ref #1

Fix #1

  • added Dockerfile
  • Reduce container re-build time from 22mins -> 2 seconds (depending on cache expiry, Using --mount=type=cache )
time podman build -t obp-api .

...

real  22m55.899s
user  37m35.264s
sys  1m48.375s

Then rebuilds will be much faster:

time podman build -t obp-api .

...
real  0m2.746s
user  0m2.754s
sys  0m1.532s

Note if cache expires or a layer changes the build will be slower, but not the worst case;

time podman build -t obp-api .
...
real	6m31.714s
user	18m43.876s
sys	0m32.894s

If you do want to build with no cache:

time podman build --no-cache -t obp-api .

# long time

@chrisjsimpson chrisjsimpson merged commit bbc2ac8 into develop Sep 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant