Playback starts YouTube’s embedded player (privacy-enhanced mode).
How to create a PEM file for HAProxy Configure SSL Certificate
ChannelATOMDescription from the creator
How to create a PEM file for HAProxy Configure SSL Certificate
fosshelp.blogspot.in/2016/11/how-to-create-pem-…
1
Generate a unique private key KEY
$sudo openssl genrsa -out mydomain.key 2048
Note:
Content in this file start with -----BEGIN RSA PRIVATE KEY-----
2
Generating a Certificate Signing Request CSR
$sudo openssl req -new -key mydomain.key -out mydomain.csr
Note:
Content in this file start with -----BEGIN CERTIFICATE REQUEST-----
3
Creating a Self-Signed Certificate CRT
$openssl x509 -req -days 365 -in mydomain.csr -signkey mydomain.key -out mydomain.crt
Note:
Content in this file start with -----BEGIN CERTIFICATE-----
4
Append KEY and CRT to mydomain.pem
$sudo bash -c 'cat mydomain.key mydomain.crt /etc/ssl/private/mydomain.pem'
Note:
This pem file contains 2 sections certificates, one start with -----BEGIN RSA PRIVATE KEY----- and another one start with -----BEGIN CERTIFICATE-----
5
Specify PEM in haproxy config
$ sudo vim /etc/haproxy/haproxy.cfg
listen haproxy
bind 0.0.0.0:443 ssl crt /etc/ssl/private/mydomain.pem
mode http
option http-server-close
option forwardfor
reqadd X-Forwarded-Proto:\ https
reqadd X-Forwarded-Port:\ 443
option forwardfor if-none
balance roundrobin
option abortonclose
server 192.168.100.224 192.168.100.224:1443 check inter 10s rise 2 fall 3 ssl verify none
6
Restart haproxy
$ sudo service haproxy restart
fosshelp.blogspot.in/2016/11/how-to-create-pem-…
1
Generate a unique private key KEY
$sudo openssl genrsa -out mydomain.key 2048
Note:
Content in this file start with -----BEGIN RSA PRIVATE KEY-----
2
Generating a Certificate Signing Request CSR
$sudo openssl req -new -key mydomain.key -out mydomain.csr
Note:
Content in this file start with -----BEGIN CERTIFICATE REQUEST-----
3
Creating a Self-Signed Certificate CRT
$openssl x509 -req -days 365 -in mydomain.csr -signkey mydomain.key -out mydomain.crt
Note:
Content in this file start with -----BEGIN CERTIFICATE-----
4
Append KEY and CRT to mydomain.pem
$sudo bash -c 'cat mydomain.key mydomain.crt /etc/ssl/private/mydomain.pem'
Note:
This pem file contains 2 sections certificates, one start with -----BEGIN RSA PRIVATE KEY----- and another one start with -----BEGIN CERTIFICATE-----
5
Specify PEM in haproxy config
$ sudo vim /etc/haproxy/haproxy.cfg
listen haproxy
bind 0.0.0.0:443 ssl crt /etc/ssl/private/mydomain.pem
mode http
option http-server-close
option forwardfor
reqadd X-Forwarded-Proto:\ https
reqadd X-Forwarded-Port:\ 443
option forwardfor if-none
balance roundrobin
option abortonclose
server 192.168.100.224 192.168.100.224:1443 check inter 10s rise 2 fall 3 ssl verify none
6
Restart haproxy
$ sudo service haproxy restart
About this tutorial
ATOM published this 6:00 video tutorial on October 31, 2017. It has been watched 26,363 times on YouTube.
Share
This tutorial in other languages
- FRComment créer un fichier PEM pour HAProxy Configurer le certificat SSL
- ESCómo crear un archivo PEM de Certificados SSL Configure HAProxy
- PTComo criar um arquivo PEM para HAProxy Configurar Certificado SSL
- ITCome creare un file PEM per HAProxy Configura certificato SSL
- DEWie eine PEM-Datei für HAProxy Konfigurieren von SSL-Zertifikat erstellen
- NLHoe maak je een PEM-bestand voor HAProxy Stel SSL Certificaat maken
- RUКак создать файл PEM для HAProxy Настройка SSL-сертификата
- PLJak utworzyć plik PEM dla HAProxy Konfiguracja certyfikatu SSL
- JAHAProxy設定SSL証明書のためのPEMファイルを作成する方法
- ARكيفية إنشاء ملف PEM لHAProxy تكوين شهادة SSL
- HIHAProxy कॉन्फ़िगर SSL प्रमाणपत्र के लिए एक पीईएम फ़ाइल बनाने के लिए कैसे
- IDCara membuat file PEM untuk HAProxy Konfigurasi SSL Certificate