LoginSignup
2
0

More than 5 years have passed since last update.

rust in docker で cargo build に失敗するときの対処法

Posted at

こんな感じのエラーが出る

root@59a819b944e6:/source# cargo build --verbose
    Updating registry `https://github.com/rust-lang/crates.io-index`
error: failed to load source for a dependency on `rand`

Caused by:
  Unable to update registry https://github.com/rust-lang/crates.io-index

Caused by:
  failed to fetch `https://github.com/rust-lang/crates.io-index`

Caused by:
  [16/-17] The SSL certificate is invalid

そんなときは

export SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt

を設定すると解決します

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0