Skip to content

Commit

Permalink
Build nidx image (#2552)
Browse files Browse the repository at this point in the history
  • Loading branch information
javitonino authored Oct 18, 2024
1 parent 293b072 commit 62ff6c1
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,5 @@ lib
logs
nats-server
nucliadb_writer/nats-server
target/*
**/target/*
tests/*
9 changes: 9 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,15 @@ jobs:
secrets:
inherit

build-nidx-image:
name: Build nidx image
uses: ./.github/workflows/_build-img-nucliadb.yml
with:
file: Dockerfile.nidx
image-name: nidx
secrets:
inherit

upload-chart-nucliadb-shared:
name: Deploy nucliadb shared
runs-on: ubuntu-latest
Expand Down
13 changes: 13 additions & 0 deletions Dockerfile.nidx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#
# Dockerfile for nucliadb's index node, compiling nidx in the docker build.
# For a version that uses pre-built binaries (outside Docker) see `Dockerfile.nidx_prebuild`
#

FROM rust:1.82.0-bookworm AS builder
RUN apt update && apt install -y protobuf-compiler
COPY nucliadb_protos/*proto /app/nucliadb_protos/
COPY nidx /app/nidx
RUN cd /app/nidx && cargo build --locked --release

FROM debian:bookworm-slim AS nidx
COPY --from=builder /app/nidx/target/release/nidx /usr/local/bin

0 comments on commit 62ff6c1

Please sign in to comment.