Skip to content

Commit

Permalink
Fix: Linux arm64 向け Docker イメージのビルドに失敗していた問題を修正
Browse files Browse the repository at this point in the history
Sudachipy では Linux arm64 向け wheel が公開されておらず、Rust を入れてもビルドエラーになる問題があり、厳しい…
  • Loading branch information
tsukumijima committed Nov 26, 2024
1 parent 6b78acc commit 2076185
Show file tree
Hide file tree
Showing 5 changed files with 107 additions and 105 deletions.
9 changes: 4 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,10 @@ ADD ./poetry.toml ./poetry.lock ./pyproject.toml /opt/aivisspeech-engine/
RUN <<EOF
/opt/python/bin/pip3 install poetry
chown -R user /opt/aivisspeech-engine
# Install Rust (wheel build dependencies)
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
source $HOME/.cargo/env
gosu user /opt/python/bin/poetry install --only=main
rm -rf /root/.cargo
# Install Rust (Sudachipy arm64 wheel build dependencies)
gosu user bash -c "curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y"
gosu user bash -c "source /home/user/.cargo/env; /opt/python/bin/poetry install --only=main"
gosu user rm -rf /home/user/.cargo
EOF

# Add local files
Expand Down
Loading

0 comments on commit 2076185

Please sign in to comment.