I am running my server on CentOS 8 stream. I used PIP to install certbot.
Now, after updating snapd is available on the system.
Which one should I use? Snapd or PIP? and why? I have the following questions.
How to uninstall pip and install snap? Do I need to uninstall PIP before installing Snap? or Can they co-exist?
Does snap require manual monthly update? or it will be updated automatically?
Does snap require python?
Will I need to update the Snap app periodically? My current version of Snap is 2.58.3-1.el8. It is not the latest. I searched the internet for upgrading Snap. But in vain.
I am using CentOS 8 stream. It has EOL during 2024. After that, do I need to upgrade my linux distro to newer version? or it will continue to work?
Does it need cron command to update the certificates automatically?
The answer to your exact question is: you can and probably should have pip and snap co-existing. However, if your question is Certbot specific, then it's very unwise to have TWO instances of Certbot installed next to each other (e.g., one instance installed using pip and another installed using snap).
Applications installed using snap are automatically updated. Pip installations are not and can lead to dependency hell. If snap itself is also automatically updated: I don't know.
No.
No.
Upgrading EOL distributions is ALWAYS a good idea and is a separate issue from snap/pip/Certbot/whatever.
No, not if you installed Certbot using snap. Certbot/snap should take care of this automatically.
No minimum version of snap required as far as I know.
I'd advise snap, unless you have principled objections. I'd only suggest pip if snap is not an option and your distro doesn't update their repository often (e.g. Debian/Ubuntu).
If you followed the instructions on https://certbot.eff.org:
1- Certbot was installed into a virtualenv contained in /opt/certbot/
2- There is a symlink from /usr/bin/certbot to /opt/certbot/bin/certbot
That can be confirmed by doing:
ls -alh /usr/bin
That will show you what Certbot links to. If it links to /opt/certbot/bin/certbot, you followed the instruction (yay!). The safest option (IMHO) would be to simply delete the symlink in /usr/bin and then install snap.
You could also just install via Snap and then check the /usr/bin to see if the symlink was overwritten to the snap version. (I believe snap uses a symlink; it is possible that it uses a prioritized bin directory in the shell configuration)
If you did not install Certbot into a virtualenv, but instead into the User or System Python packages systems... That can be somewhat advanced to remove safely. The only tips I can give in that situation, is checking which Certbot gets invoked (which certbot, followed by ls -alh {that path}) and checking your shell configurations. Aside from that, good luck!