Hey Folks, I was way busy lately, and I missed out on my renewal period for letsencrypt, plus FreeBSD had some changes for letsencrypt, met with a few erros and thought it might help someone.
Note if you are using a Fresh new version of FreeBSD, then you are better off by just doing the following pkg install and skipping to theĀ Run it! section.
pkg install py27-certbot
Ran the update the way I used to, and I started hitting an error:
sudo letsencrypt certonly --non-interactive --webroot -w /usr/local/www/hackersmu/hackers.mu/ -d www.hackers.mu -d hackers.mu --debug --agree-tos --email justAname@hackers.mu
Traceback (most recent call last): File "/usr/local/bin/letsencrypt", line 5, in from pkg_resources import load_entry_point File "/usr/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2927, in @_call_aside File "/usr/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2913, in _call_aside f(*args, **kwargs) File "/usr/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2940, in _initialize_master_working_set working_set = WorkingSet._build_master() File "/usr/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 637, in _build_master return cls._build_from_requirements(__requires__) File "/usr/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 650, in _build_from_requirements dists = ws.resolve(reqs, Environment()) File "/usr/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 829, in resolve raise DistributionNotFound(req, requirers) pkg_resources.DistributionNotFound: The 'parsedatetime<2.0' distribution was not found and is required by letsencrypt
short version: seems the port was renamed to py-certbot
So:
Get the package name and version of the previous package.
$ sudo pkg info |grep letsencrypt
py27-letsencrypt-0.4.1 Let's Encrypt client
$ sudo portmaster -o security/py-certbot py27-letsencrypt-0.4.1
at first it couldn’t find certbot, then I realized I need to update my ports directory,
sudo portsnap fetch update
….wait some time…
then relaunch the portmaster command as directed above.
Run it!
the rest is as simple as:
sudo certbot certonly --non-interactive --webroot -w /usr/local/www/hackersmu/hackers.mu/ -d www.hackers.mu -d hackers.mu --debug --agree-tos --email selven@hackers.mu
if you want this to run quietly and automatically for you, try
certbot renew --quiet