LoginSignup
0
0

More than 1 year has passed since last update.

Could not create yum cacheエラー対応

Posted at

エラー内容

AWS ElasticBeanstalkでのデプロイ時、エラーが発生しアプリケーションをデプロイできなかった。

Command failed on instance. Return code: 1 Output: Could not create yum cache (return code 1). Package listed in EBExtension failed to install. For more detail, check /var/log/eb-activity.log using console or EB CLI.

調査

インスタンスに乗り込み、activity.logを確認したところ、yum install yarnができなかった様子。

その直前のコマンドが下記。おそらくこれがコケたから、上記yarnのinstallができなかったのだろうと推測。

curl -sL https://dl.yarnpkg.com/rpm/yarn.repo | sudo tee /etc/yum.repos.d/yarn.repo

上記curlを叩いたところ、調査時点では正しく返ってくる。
ただし、その時点での/etc/yum.repos.d/yarn.repoの中身を見ると500エラーが返っている内容であったため、デプロイ失敗時にはyarnレポからうまく取得できなかったのだろう。

対応

上記のコマンドをインスタンス内で実行し、再度デプロイすることで問題は解消した。

原因

おそらく、Cloudflareでの障害が起因している。

以上

0
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
0
0