-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5 from tthogho1/websocket_QA
set static folder to / path
- Loading branch information
Showing
2 changed files
with
31 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
FROM rust:1.70-slim-buster AS builder | ||
|
||
WORKDIR /app | ||
|
||
# 依存関係のキャッシュ | ||
COPY Cargo.toml Cargo.lock askama.toml ./ | ||
|
||
COPY src ./src | ||
RUN ls -la ./src | ||
COPY templates ./templates | ||
RUN ls -la ./templates | ||
COPY static ./static | ||
RUN ls -la ./static | ||
|
||
# RUN mkdir src && echo "fn main() {}" > src/main.rs | ||
RUN cargo build --release | ||
RUN rm -rf src | ||
|
||
#CMD ["/app/target/release/websocket_rust"] | ||
|
||
|
||
# 実行ステージ | ||
FROM debian:buster-slim | ||
|
||
RUN apt-get update && rm -rf /var/lib/apt/lists/* | ||
|
||
COPY --from=builder /app/target/release/websocket_rust /usr/local/bin/websocket_rust | ||
|
||
CMD ["websocket_rust"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters