Skip to content

SSL for a custom app #721

Answered by brettpetch
bar1bar1 asked this question in Q&A + Help
Discussion options

You must be logged in to vote

Make relevant A/AAAA/CNAME records with your domain registrar, then generate certs.

export LE_HOSTNAME="example.com"
export LE_DEFAULTCONF=no
box install letsencrypt

Relevant Documentation: https://docs.photoprism.org/getting-started/proxies/nginx/

# /etc/nginx/sites-enabled/photos.example.com.conf
server {
  listen 443 ssl;
  listen [::]:443 ssl;
  server_name photos.example.com
  client_max_body_size 500M;

  # With SSL via Let's Encrypt
  ssl_certificate /etc/nginx/ssl/photos.example.com/fullchain.pem;
  ssl_certificate_key /etc/nginx/ssl/photos.example.com/key.pem;
  include snippets/ssl-params.conf;

  location / {
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    p…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by brettpetch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants