Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

setup ros2 keyでSSLのエラーが出る #192

Open
TatsukiNishimura opened this issue May 28, 2022 · 2 comments
Open

setup ros2 keyでSSLのエラーが出る #192

TatsukiNishimura opened this issue May 28, 2022 · 2 comments
Labels
bug Something isn't working

Comments

@TatsukiNishimura
Copy link

sh setup.sh

を実行してros2のインストールをする際、
setup ros2 keyのタスクで

Request failed: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1131)>

のエラーが出てしまう。

環境

  • Ubuntu 20.04 LTS
  • ROS galactic
@TatsukiNishimura TatsukiNishimura added the bug Something isn't working label May 28, 2022
@TatsukiNishimura
Copy link
Author

TatsukiNishimura commented May 28, 2022

pythonのインタプリタで

>>> import certifi
>>> certifi.where()

の結果を取得して、

- name: setup ros2 keys

name: setup ros2 keys
  become: yes
  get_url:
    url: "https://raw.githubusercontent.com/ros/rosdistro/master/ros.key"
    dest: /usr/share/keyrings/ros-archive-keyring.gpg
  environment:
    SSL_CERT_FILE: (certifi.where()で得られたパス)

を書き加えるとエラーがなくなった。
ただ、このパスは人によって異なるからどうすればいいんだろう…

@hakuturu583
Copy link
Member

この方法は @TatsukiNishimura くん環境特有のものかもしれないですが、なんとかならないか要検討ですね
pythonのスクリプトを実行して環境変数に書き込むのはansibleでできると思うので、問題はこのステップがなぜ必要になっているのかという気はします。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants