[A-00083]gcloudSDKのpythonのパスを変更する
gcloudはpythonを使用しています。pythonのバージョンが古いと下記のエラーが表示されます。
WARNING: Python 3.5-3.7 will be deprecated on August 8th, 2023. Please use Python version 3.8 and up.
If you have a compatible Python interpreter installed, you can use it by setting
the CLOUDSDK_PYTHON environment variable to point to it.
上記の場合、gcloudが参照しているpythonのバージョンが非推奨なのでパスを変える必要があります。
下記のように.bashrcもしくは.bash_profile(zshは.zshrc)に環境変数を追加します。
export CLOUDSDK_PYTHON=$(which python3)
bash ~/.bash_profile
上記の変数を追加した後gcloudを実行すると最初に出たエラーは出なくなります。
コメントを残す