Skip to content

Commit

Permalink
removed duplicated dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
yinho999 committed Jan 20, 2025
1 parent af50d5f commit 328ccae
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 51 deletions.
13 changes: 10 additions & 3 deletions loco-gen/src/templates/deployment/docker/docker.t
Original file line number Diff line number Diff line change
@@ -1,8 +1,15 @@
to: "dockerfile"
skip_exists: true
message: "Dockerfile generated successfully."

injections:
- into: config/development.yaml
after: " port: 5150"
content: " # Expose Server on all interfaces\n binding: 0.0.0.0"

---
FROM rust:1.83.0-slim as builder

FROM rust:1.84-slim as builder

WORKDIR /usr/src/

Expand All @@ -13,14 +20,14 @@ RUN cargo build --release
FROM debian:bookworm-slim

WORKDIR /usr/app

{% if copy_asset_folder -%}
COPY --from=builder /usr/src/{{copy_asset_folder}} /usr/app/{{copy_asset_folder}}
{% endif -%}
COPY --from=builder /usr/src/assets/views /usr/app/assets/views
{% if fallback_file -%}
COPY --from=builder /usr/src/{{fallback_file}} /usr/app/{{fallback_file}}
{% endif -%}
COPY --from=builder /usr/src/config /usr/app/config
COPY --from=builder /usr/src/target/release/{{pkg_name}}-cli /usr/app/{{pkg_name}}-cli

ENTRYPOINT ["/usr/app/{{pkg_name}}-cli"]
ENTRYPOINT ["/usr/app/{{pkg_name}}-cli","start"]
2 changes: 1 addition & 1 deletion loco-gen/src/templates/deployment/kamal/deploy.t
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ builder:
arch: amd64
# Pass in additional build args needed for your Dockerfile.
# args:

dockerfile: dockerfile
# Inject ENV variables into containers (secrets come from .kamal/secrets).
#
# env:
Expand Down
47 changes: 0 additions & 47 deletions loco-gen/src/templates/deployment/kamal/docker.t

This file was deleted.

0 comments on commit 328ccae

Please sign in to comment.