Asciinema Error

Posted by Andrew Denner on April 27, 2022 · 1 min read

Asciinema is a great youtube like recorder for your Linux terminal. It is great for demos and tech previews so that the sacrifices to the demo gods can be pre-staged.

Tonight in a docker image (er ok it was in podman, but a container is a container) of ubuntu:latest (we are now at 22.04 Jammy Jellyfish) when I installed the client via the command:

sudo apt update
sudo apt install asciinema

Things went well until I was done and exited, triggering the upload. I got the error

asciinema: upload failed: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:997)>
asciinema: retry later by running: asciinema upload /tmp/tmpbxqoh2wy-ascii.cast

After some googling I found an old issue with a hint on how to solve it. (yes it was for OS X but the same kind of problem, a bad SSL/TLS certificate store)

 apt install python3-pip
 pip install --upgrade certifi

Yes, I realize this is rather heavy-handed installing python and pip just to grab some certs but this is a container that I am going to throw away anyway, so YOLO!

After that finished I was able to go forward with the command

asciinema upload /tmp/tmpbxqoh2wy-ascii.cast