User Tools

Site Tools


linux:certbot_cheatsheet

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Last revisionBoth sides next revision
linux:certbot_cheatsheet [2022/06/30 09:19] dodgerlinux:certbot_cheatsheet [2022/11/08 08:49] – [Show certificates] dodger
Line 9: Line 9:
 One liner of the dead to show all the certificates an file identifier: One liner of the dead to show all the certificates an file identifier:
 <code bash> <code bash>
-/usr/bin/certbot certificates | egrep "Name|Domains" 2> /dev/null | while read LINE ; do [[ "${LINE}" =~ Certificate\ Name:\ (.*)$ ]] && CERTNAME=${BASH_REMATCH[1]} ; [[ "${LINE}" =~ Domains:\ (.*)$ ]] +/usr/bin/certbot certificates | egrep "Name|Domains" 2> /dev/null | while read LINE ; do 
- && DOMAIN_LIST=${BASH_REMATCH[1]} ; if [[ "${DOMAIN_LIST}" ]] ; then echo "####### ${CERTNAME} ->" ; for i in  ${DOMAIN_LIST} ; do echo ${i} ; done | sort  ; DOMAIN_LIST=""; CERTNAME="" ; fi ;  done+  [[ "${LINE}" =~ Certificate\ Name:\ (.*)$ ]] && CERTNAME=${BASH_REMATCH[1]} ; 
 +  [[ "${LINE}" =~ Domains:\ (.*)$ ]] && DOMAIN_LIST=${BASH_REMATCH[1]} ; 
 +  if [[ "${DOMAIN_LIST}" ]] ; then echo "####### ${CERTNAME} ->" ; 
 +  for i in  ${DOMAIN_LIST} ; do 
 +    echo ${i} ; done | sort  ; 
 +    DOMAIN_LIST=""; CERTNAME="" ; fi ; done
 </code> </code>
  
linux/certbot_cheatsheet.txt · Last modified: 2023/02/27 09:13 by dodger