1
0
mirror of https://github.com/certbot/certbot.git synced 2026-01-14 23:22:21 +03:00
Files
certbot/docs/using.rst
James Kasten 2a41c6b27c Merge pull request #748 from kuba/freebsd
Add basic setup for FreeBSD
2015-09-08 16:17:01 -04:00

3.9 KiB

Using the Let's Encrypt client

Quick start

Using Docker you can quickly get yourself a testing cert. From the server that the domain your requesting a cert for resolves to, install Docker, issue the following command:

sudo docker run -it --rm -p 443:443 --name letsencrypt \
            -v "/etc/letsencrypt:/etc/letsencrypt" \
            -v "/var/lib/letsencrypt:/var/lib/letsencrypt" \
            quay.io/letsencrypt/letsencrypt:latest

and follow the instructions. Your new cert will be available in /etc/letsencrypt/certs.

Getting the code

Please install Git and run the following commands:

git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt

Alternatively you could download the ZIP archive and extract the snapshot of our repository, but it's strongly recommended to use the above method instead.

Prerequisites

The demo code is supported and known to work on Ubuntu and Debian. Therefore, prerequisites for other platforms listed below are provided mainly for the developers <hacking> reference.

In general:

  • sudo is required as a suggested way of running privileged process
  • Augeas is required for the Python bindings

Ubuntu

sudo ./bootstrap/ubuntu.sh

Debian

sudo ./bootstrap/debian.sh

For squeeze you will need to:

  • Use virtualenv --no-site-packages -p python instead of -p python2.

Mac OSX

./bootstrap/mac.sh

Fedora

sudo ./bootstrap/fedora.sh

Centos 7

sudo ./bootstrap/centos.sh

FreeBSD

sudo ./bootstrap/freebsd.sh

Bootstrap script for FreeBSD uses pkg for package installation, i.e. it does not use ports.

FreeBSD by default uses tcsh. In order to activate virtulenv (see below), you will need a compatbile shell, e.g. pkg install bash && bash.

Installation

virtualenv --no-site-packages -p python2 venv
./venv/bin/pip install -r requirements.txt acme/ . letsencrypt-apache/ letsencrypt-nginx/

Warning

Please do not use python setup.py install. Please do not attempt the installation commands as superuser/root and/or without Virtualenv, e.g. sudo python setup.py install, sudo pip install, sudo ./venv/bin/.... These modes of operation might corrupt your operating system and are not supported by the Let's Encrypt team!

Usage

To get a new certificate run:

sudo ./venv/bin/letsencrypt auth

The letsencrypt commandline tool has a builtin help:

./venv/bin/letsencrypt --help

Configuration file

It is possible to specify configuration file with letsencrypt --config cli.ini (or shorter -c cli.ini). For instance, if you are a contributor, you might find the following handy:

By default, the following locations are searched:

  • /etc/letsencrypt/cli.ini
  • $XDG_CONFIG_HOME/letsencrypt/cli.ini (or ~/.config/letsencrypt/cli.ini if $XDG_CONFIG_HOME is not set).