chore: profile appflowy cloud (#311)
This commit is contained in:
parent
a1494f0d09
commit
8769ae62f7
|
|
@ -162,9 +162,7 @@ codegen-units = 1
|
||||||
|
|
||||||
[profile.profiling]
|
[profile.profiling]
|
||||||
inherits = "release"
|
inherits = "release"
|
||||||
codegen-units = 16
|
|
||||||
debug = true
|
debug = true
|
||||||
lto = false
|
|
||||||
|
|
||||||
[patch.crates-io]
|
[patch.crates-io]
|
||||||
collab = { git = "https://github.com/AppFlowy-IO/AppFlowy-Collab", rev = "2de6d172f56fed29ee6f32b82040cca4867647ac" }
|
collab = { git = "https://github.com/AppFlowy-IO/AppFlowy-Collab", rev = "2de6d172f56fed29ee6f32b82040cca4867647ac" }
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@ COPY . .
|
||||||
ENV SQLX_OFFLINE true
|
ENV SQLX_OFFLINE true
|
||||||
|
|
||||||
# Build the project
|
# Build the project
|
||||||
RUN cargo build --release --bin appflowy_cloud
|
RUN cargo build --profile=profiling --bin appflowy_cloud
|
||||||
|
|
||||||
FROM debian:bookworm-slim AS runtime
|
FROM debian:bookworm-slim AS runtime
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
@ -27,7 +27,7 @@ RUN apt-get update -y \
|
||||||
&& apt-get clean -y \
|
&& apt-get clean -y \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
COPY --from=builder /app/target/release/appflowy_cloud /usr/local/bin/appflowy_cloud
|
COPY --from=builder /app/target/profiling/appflowy_cloud /usr/local/bin/appflowy_cloud
|
||||||
ENV APP_ENVIRONMENT production
|
ENV APP_ENVIRONMENT production
|
||||||
ENV RUST_BACKTRACE 1
|
ENV RUST_BACKTRACE 1
|
||||||
CMD ["appflowy_cloud"]
|
CMD ["appflowy_cloud"]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue