perf(backend): Cache build of dependencies

When building the Docker image, first compile the project with a fake
main file, namely `dummy.rs`. Once dependencies are built, compile the
actual project by switching back to `src/main.rs`.

Signed-off-by: Lucien Cartier-Tilet <lucien@phundrak.com>
This commit is contained in:
2023-02-09 11:59:39 +01:00
parent fd71b959f1
commit 8e925b884e
3 changed files with 16 additions and 3 deletions

1
dummy.rs Normal file
View File

@@ -0,0 +1 @@
fn main() {}