letsencrypt – certbot(python) ssl 적용 (1부)

  • 환경
    CentOS 7 / Python 2.7
  • 시작하기전에
    환경이나 조건별로 설치 방법이 다른 부분이 있으니 certbot 을 참고 하기 바랍니다.
    본 글은 python pip 를 사용하여 certbot 을 설치 하는 방법으로 certbot 내용과 다른점이 있으니 참고 사항으로만 확인 부탁드립니다.
  • python pip 를 이용한 certbot 설치
    ] pip install certbot

letsencrypt SSL 신규 발행

] certbot certonly
Saving debug log to /var/log/letsencrypt/letsencrypt.log
How would you like to authenticate with the ACME CA?
1: Spin up a temporary webserver (standalone)
2: Place files in webroot directory (webroot)
Select the appropriate number [1-2] then [enter] (press 'c' to cancel): 2
# 1 : 임시 웹서버를 구동하여 진행
# 2 : 사용중인 웹서버를 이요하여 진행 
Plugins selected: Authenticator webroot, Installer None
Please enter in your domain name(s) (comma and/or space separated)  (Enter 'c'
to cancel): test.com
# 인증서를 발급받을 도메인 주소
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for test.com
Select the webroot for test.com:
1: Enter a new webroot
Press 1 [enter] to confirm the selection (press 'c' to cancel): 1
Input the webroot for pic.huubro.com: (Enter 'c' to cancel): /tmp/www
Waiting for verification...
Cleaning up challenges
- Congratulations! Your certificate and chain have been saved at:
Your key file has been saved at:
Your cert will expire on 2018-02-04. To obtain a new or tweaked
version of this certificate in the future, simply run certbot
again. To non-interactively renew *all* of your certificates, run
"certbot renew"
- If you like Certbot, please consider supporting our work by: 
Donating to ISRG / Let's Encrypt:   https://letsencrypt.org/donate
Donating to EFF:                    https://eff.org/donate-le

인증서 발급 완료
/etc/letsencrypt/live/{도메인} 디렉토리에 아래 (인증서)파일이 생성됨을 확인

] ls /etc/letsencrypt/liv/test.com
  • 웹서버 SSL 설정
  • letsencrypt SSL 갱신
    ] certbot renew

2부에서 계속