diff --git a/Dockerfile b/Dockerfile index 0bc5f8d9..c2ae4c85 100644 --- a/Dockerfile +++ b/Dockerfile @@ -245,5 +245,7 @@ ENTRYPOINT ["./entrypoint.sh"] # Final image FROM base -ENTRYPOINT ["text-generation-launcher"] +COPY ./tgi-entrypoint.sh /tgi-entrypoint.sh + +ENTRYPOINT ["/tgi-entrypoint.sh"] CMD ["--json-output"] diff --git a/launcher/src/main.rs b/launcher/src/main.rs index 3f810023..836b0381 100644 --- a/launcher/src/main.rs +++ b/launcher/src/main.rs @@ -1217,16 +1217,6 @@ fn terminate(process_name: &str, mut process: Child, timeout: Duration) -> io::R } fn main() -> Result<(), LauncherError> { - match Command::new("ldconfig").spawn() { - Ok(_) => {} - Err(err) => { - tracing::warn!( - "Unable to refresh ldconfig cache. Skipping (useless in most cases). Details {:?}", - err - ) - } - } - // Pattern match configuration let args: Args = Args::parse(); diff --git a/tgi-entrypoint.sh b/tgi-entrypoint.sh new file mode 100755 index 00000000..ea94dcd9 --- /dev/null +++ b/tgi-entrypoint.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +ldconfig 2>/dev/null || echo 'unable to refresh ld cache, not a big deal in most cases' + +text-generation-launcher $@