I have an Ubuntu 20.04 server running with Apache and Nginx. I want to add an SSL certificate using Certbot but I don't know how to proceed.
My project consists of a django api and a Vue js frontend. Nginx is responsible for the API and apache acts as a reverse proxy.
My Apache 000-default.conf file
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
<VirtualHost *:80>
ServerName ***.***.** <- My IP
ProxyPass / http://127.0.0.1:8000/
ProxyPassReverse / http://127.0.0.1:8000/
</VirtualHost>
My Nginx config
upstream django {
server unix:///home/backend/mysite.sock;
}
server {
listen 8000;
server_name mysite.com;
charset utf-8;
client_max_body_size 75M;
location /media {
alias /home/backend/media;
}
location /static {
alias /home/backend/static;
}
location / {
uwsgi_pass django;
include /home/backend/uwsgi_params;
}
}
Thank you if someone informs me how can I install an ssl certificate with Certbot using this configuration