Skip to content

Commit

Permalink
test3
Browse files Browse the repository at this point in the history
  • Loading branch information
johndeniel committed Jun 10, 2024
1 parent d4d369d commit ec42538
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 22 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build-deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ jobs:
file: ./Dockerfile
builder: ${{ steps.buildx.outputs.name }}
push: true
tags: ${{ secrets.DOCKER_HUB_USERNAME }}/spotify:build-v1.001
tags: ${{ secrets.DOCKER_HUB_USERNAME }}/skylark:build-v1.001
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}
run: echo ${{ steps.docker_build.outputs.digest }}
26 changes: 13 additions & 13 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "spotify"
name = "logging"
version = "0.1.0"
edition = "2021"

Expand Down
10 changes: 5 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM messense/rust-musl-cross:x86_64-musl as chef
RUN cargo install cargo-chef
WORKDIR /spotify
WORKDIR /logging

FROM chef AS planner
# Copy source code from previous stage
Expand All @@ -9,7 +9,7 @@ COPY . .
RUN cargo chef prepare --recipe-path recipe.json

FROM chef AS builder
COPY --from=planner /spotify/recipe.json recipe.json
COPY --from=planner /logging/recipe.json recipe.json
# Build & cache dependencies
RUN cargo chef cook --release --target x86_64-unknown-linux-musl --recipe-path recipe.json
# Copy source code from previous stage
Expand All @@ -19,6 +19,6 @@ RUN cargo build --release --target x86_64-unknown-linux-musl

# Create a new stage with a minimal image
FROM scratch
COPY --from=builder /spotify/target/x86_64-unknown-linux-musl/release/spotify /spotify
ENTRYPOINT ["/spotify"]
EXPOSE 7860
COPY --from=builder /logging/target/x86_64-unknown-linux-musl/release/logging /logging
ENTRYPOINT ["/logging"]
EXPOSE 7860
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use spotify::run;
use logging::run;

#[tokio::main]
async fn main() {
Expand Down

0 comments on commit ec42538

Please sign in to comment.