Skip to content

Commit

Permalink
build: 尝试优化镜像大小
Browse files Browse the repository at this point in the history
  • Loading branch information
liqiang-fit2cloud committed Apr 11, 2024
1 parent 5b2a0c8 commit 7b644ae
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-and-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
inputs:
dockerImageTag:
description: 'Docker Image Tag'
default: 'v1.0.0-dev'
default: 'v1.1.0-dev'
required: true
architecture:
description: 'Architecture'
Expand Down
5 changes: 2 additions & 3 deletions installer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,15 @@ ENV MAXKB_VERSION ${DOCKER_IMAGE_TAG} (build at ${BUILD_AT}, commit: ${GITHUB_CO
WORKDIR /opt/maxkb/app
COPY --from=stage-build /opt/maxkb /opt/maxkb
COPY --from=stage-build /opt/py3 /opt/py3
COPY --from=vector-model /opt/maxkb/app/model /opt/maxkb/app/model
COPY --from=vector-model /opt/maxkb/app/model /opt/maxkb/model

ENV LANG=en_US.UTF-8 \
PATH=/opt/py3/bin:$PATH

ENV POSTGRES_USER root
ENV POSTGRES_PASSWORD Password123@postgres

RUN mv /opt/maxkb/app/model/* /opt/maxkb/model && \
chmod 755 /opt/maxkb/app/installer/run-maxkb.sh && \
RUN chmod 755 /opt/maxkb/app/installer/run-maxkb.sh && \
cp -r /opt/maxkb/model/base/hub /opt/maxkb/model/tokenizer && \
cp -f /opt/maxkb/app/installer/run-maxkb.sh /usr/bin/run-maxkb.sh && \
cp -f /opt/maxkb/app/installer/init.sql /docker-entrypoint-initdb.d
Expand Down

0 comments on commit 7b644ae

Please sign in to comment.